SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 11/06/2019, 05:32 PM   #1
wilking
Big Clucker
 
Join Date: May 2017
Posts: 57
Reputation: 0
Default help me dialog problem

https://imgur.com/4W3ezr5

Help me , i need down the line [\n] , this text edit ingame on dialog_input and save to database .

when show it not work . help me please ...

i have varchar for text .
wilking is offline   Reply With Quote
Old 11/06/2019, 05:57 PM   #2
Calisthenics
Gangsta
 
Join Date: May 2018
Posts: 558
Reputation: 92
Default Re: help me dialog problem

\n is a special character but when trying to save it, it thinks of it as two different characters. Convert it to a symbol that is not used in your text and store it in database. When you retrieve it, convert it back to original.
Calisthenics is offline   Reply With Quote
Old 11/06/2019, 06:22 PM   #3
NaS
High-roller
 
NaS's Avatar
 
Join Date: Mar 2008
Location: 🇩🇪
Posts: 1,625
Reputation: 535
Default Re: help me dialog problem

You could replace them back to actual escape characters after loading them. Or escape your string properly before saving it.
NaS is offline   Reply With Quote
Old 11/06/2019, 06:30 PM   #4
Koreadars
Big Clucker
 
Join Date: Mar 2019
Location: Czech Republic, Prdelákov.
Posts: 123
Reputation: 6
Default Re: help me dialog problem

Or simply always do:
pawn Code:
strcat(xxx, "\n");
Koreadars is offline   Reply With Quote
Old 11/06/2019, 08:54 PM   #5
wilking
Big Clucker
 
Join Date: May 2017
Posts: 57
Reputation: 0
Default Re: help me dialog problem

Is this possible?

help me "\n" help me ...
wilking is offline   Reply With Quote
Old 12/06/2019, 04:32 AM   #6
Koreadars
Big Clucker
 
Join Date: Mar 2019
Location: Czech Republic, Prdelákov.
Posts: 123
Reputation: 6
Default Re: help me dialog problem

Everything is possible!
Koreadars is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[DIALOG]How i Create A dialog Whent Player Login To Enter in Dialog The Password donhu789 Scripting Help 8 29/09/2013 07:15 AM
Login Dialog problem - dialog too small Saddin Scripting Help 3 19/08/2012 03:58 PM
Dialog problem gnoomen2 Scripting Help 3 11/08/2012 02:50 PM
Big problem (PlayerDialogResponse PlayerId: 57 dialog ID doesn't match last sent dialog ID) RingoRus Server Support 3 12/06/2012 05:54 PM
[REP+] Dialog problem, case 1 causing errors, case 2 and 3 works fine, cant find problem niels44 Scripting Help 0 21/04/2012 06:44 PM


All times are GMT. The time now is 05:42 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.