Dialog Style Input - How to use "inputtext"? (and error help) - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Dialog Style Input - How to use "inputtext"? (and error help) (
/showthread.php?tid=516357)
Dialog Style Input - How to use "inputtext"? (and error help) -
Aerotactics - 30.05.2014
Brief: I'm getting an error, and I've tried everything to fix it. My question about it is how do you use "inputtext" correctly?
Код:
array sizes do not match, or destination array is too small
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == DIALOG_BIZNAME)
{
if(response)
{
new bizedit = IsEditingBiz[playerid];
IsEditingBiz[playerid] = -1;
bInfo[bizedit][bizname] = inputtext; <-- error line
UpdateBizTD(bizedit);
return 1;
}
return 1;
}
return 0;
}
Re: Dialog Style Input - How to use "inputtext"? (and error help) -
Vince - 30.05.2014
strcpy. Search it.
Re: Dialog Style Input - How to use "inputtext"? (and error help) -
Yako - 30.05.2014
myStrcpy(bInfo[bizedit][bizname], inputtext);
Re: Dialog Style Input - How to use "inputtext"? (and error help) -
Aerotactics - 30.05.2014
Quote:
Originally Posted by Vince
strcpy. Search it.
|
Quote:
Originally Posted by Yako
myStrcpy(bInfo[bizedit][bizname], inputtext);
|
Thanks so much! Rep each.
Re: Dialog Style Input - How to use "inputtext"? (and error help) -
Dubya - 31.05.2014
pawn Код:
#define strcpy(%1, %2) format(%1, sizeof(%1), "%s", %2)