Jump to content

Recommended Posts

Posted (edited)

Hi Scripters,

I have a string I captured from a web page and it has somewhere in it a newline char (I know that there are several different types of this but I have no idea how they differ), since when I write it to a text file it shows up in two lines, which makes the file useless for importing it to my financial software.

How could I get rid of the offending new line char? I have tried StringStripCR, it did nothing. Any ideas?

Thanks a lot!

Viktor

Edited by Viktor
Posted

Good guess! :) Worked! Thanks a lot! Viktor

  Piano_Man said:

I'm guessing there might not be CR's but rather CRLF...

Try

StringReplace($yourText, @CRLF, " ")
If that doesn't work trying using the same thing except with @LF
Posted

Good guess! :) Worked! Thanks a lot! Viktor

  Piano_Man said:

I'm guessing there might not be CR's but rather CRLF...

Try

StringReplace($yourText, @CRLF, " ")
If that doesn't work trying using the same thing except with @LF

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...