Jump to content
Sign in to follow this  
Gnat

Help with Edit fields

Recommended Posts

Gnat

Is there a way to use the edit field with the edit style of $ES_WANTRETURN, and then take that text and write it to a text file, so that when you read it back, the @CRLF does not cause the data to be read as multiple lines. Can the @CRLF be replaced by some misc. character when written to the file (FileWriteLine), and then written back when read back from the file (FileReadLine)?

Share this post


Link to post
Share on other sites
phillip123adams

Can the @CRLF be replaced by some misc. character when written to the file (FileWriteLine), and then written back when read back from the file (FileReadLine)?

<{POST_SNAPBACK}>

Do you mean?

FileWriteLine($filehandle, StringTrimRight($sMyString, 1))

Then

$sMyString = FileReadLine($filehandle) & @CRLF

Phillip

Share this post


Link to post
Share on other sites
Gigglestick

Can the @CRLF be replaced by some misc. character when written to the file (FileWriteLine), and then written back when read back from the file (FileReadLine)?

FileWriteLine($file, StringReplace($line, @CRLF, "~"))

$line = StringReplace(FileReadLine($file), "~", @CRLF)

My UDFs: ExitCodes

Share this post


Link to post
Share on other sites
Gigglestick

FileWriteLine($filehandle, StringTrimRight($sMyString, 1))
This would only remove the last @CRLF, not the ones in the middle of the text.

My UDFs: ExitCodes

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.