SA-MP Forums Archive
String length - 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: String length (/showthread.php?tid=403027)



String length - cotyzor - 28.12.2012

I want to put 20 characters limit at passwords ... what is right code ?


Re: String length - fordawinzz - 28.12.2012

Use strlen.


Re: String length - RedCrossER - 28.12.2012

You use dialog?


Re: String length - FTLOG - 28.12.2012

If you use dialogs, you can use this OnDialogResponse.

Код:
if( strlen( inputtext ) > 20 ) return SendClientMessage( playerid, 0xFFFFFFFF, "Your password is too long." );