Odd compiler error... -
Scenario - 15.12.2011
I have this piece of code here:
pawn Code:
timer SendRegistrationEmail[3000](playerid)
{
new szString[750];
format(szString, sizeof(szString), "Hello there,<p>This email is to inform you that you have registered an account at %s (IP: %s), using the username %s.</p><p>We have recorded your IP address as %s and auto-login is not currently enabled. To enable it, please go in-game and do the command /accountsettings.</p><p><p>Please do not respond to this email, as it will not be sent to anyone.</p></p><p>Best Regards,</p><p>IG:RP Management</p>", SERVNAME, returnServerStringVar("bind"), GetName(playerid), returnIP(playerid));
SendMail(pStats[playerid][EP_EMAILADDR], "donotreply@server.inimical-gaming.com", "IG:RP Team", "Greetings From The IG:RP Team", szString);
}
I am receiving the following error:
Code:
C:\Users\Piccoli\Desktop\SA-MP 0.3d\gamemodes\IGRP.pwn(831) : error 075: input line too long (after substitutions)
Now, this happens only when the code above is commented out- if it isn't, the compiler crashes.
Line 831 is this one:
Does anyone know why such an error would appear on that line?
Re: Odd compiler error... -
Steven82 - 15.12.2011
Put a space in the middle of that long format line somewhere. It pretty much is saying your line is huge please start a new line for this piece of code. I experienced this with working with MySQL querys.
Re: Odd compiler error... -
Scenario - 15.12.2011
Quote:
Originally Posted by Steven82
Put a space in the middle of that long format line somewhere. It pretty much is saying your line is huge please start a new line for this piece of code. I experienced this with working with MySQL querys.
|
I removed a chunk of the text and it's working fine now, that's weird though because my saveCharacter() function has MUCH larger strings...
Re: Odd compiler error... -
Steven82 - 15.12.2011
Quote:
Originally Posted by RealCop228
I removed a chunk of the text and it's working fine now, that's weird though because my saveCharacter() function has MUCH larger strings... ![Smiley](images/smilies/smile.png)
|
Yeah i noticed that for my functions too. One set of strings are bigger than the other and then only one line will be displaying that error? It's weird...lol.
Re: Odd compiler error... -
Joe Staff - 15.12.2011
It has to do with long strings. You can concatenate strings to work around it. I think it has to do with compiler limitations.
Re: Odd compiler error... - XFlawless - 15.12.2011
Use strcat. I had same problem with Dialogs, strcat() fixes the problem
![Smiley](images/smilies/smile.png)
.
HTML Code:
<p><p>Please do not respond to this email, as it will not be sent to anyone.</p></p>
<br/><p></p> would do :p
Re: Odd compiler error... - suhrab_mujeeb - 15.12.2011
Here is what I found when I had the same error.
Quote:
Originally Posted by HyperZ
On top of ur script:
OnGameModeInit/OnFilterScriptInit:
Command:
pawn Code:
ShowPlayerDialog(playerid, 555555, DIALOG_STYLE_MSGBOX,"Dialog Title",LongDialog, "button 1", "button 2");
Somewhere in ur script
pawn Code:
SetUpMyText() { LongDialog = "Bla bla bal\n"; strcat(LongDialog, "Bla bla bal\n"); strcat(LongDialog, "Bla bla bal\n"); strcat(LongDialog, "Bla bla bal\n"); strcat(LongDialog, "Bla bla bal\n"); return 1; )
|
Re: Odd compiler error... -
Scenario - 15.12.2011
It seems to be working now guys, thanks.