I get an old recordset from the sql server database.

And I use server side vbcode to write javascript onto a webpage.
The problem I get is that in some of the records I find CR and LF, that makes the javascript garbage...

For every string I write in the javascript, I perform a replace using \n

But yet the LF and CR remains. I checked the output in the hex editor and I find both 0D and 0A... and yet the replace method has replaced the \n with a blank...

So, are there any other ways in vb to completly get rid of the Carraige returns??


kind regards
Henrik