469,632 Members | 1,732 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,632 developers. It's quick & easy.

carriage return in a string disappears

sys
I have a web method that returns a string. When I return a string that has a
carriage return and line feed in it ("\r\n") on the client side I only
receive a string including the line feed ("\n"). The carriage return
disappeared.
Thanks for any help.
Nov 23 '05 #1
2 2147
Hi,

- Are you crossing OS boundries?
- Which toolkits are used? (Server & Client)

Marvin Smit.
On Tue, 30 Aug 2005 02:38:10 -0700, sys
<sy*@discussions.microsoft.com> wrote:
I have a web method that returns a string. When I return a string that has a
carriage return and line feed in it ("\r\n") on the client side I only
receive a string including the line feed ("\n"). The carriage return
disappeared.
Thanks for any help.


Nov 23 '05 #2
sys
Thanks for your answer.
The server and the client are using the same OS. The effect appears even if
the server and the client run on the same machine. I don't use any special
toolkits.
The error is very easy to reproduce, just make a call to the following web
method:

[WebMethod]
public string Test()
{
return "\r\n";
}

On the client I get only "\n" as result.
"Marvin Smit" wrote:
Hi,

- Are you crossing OS boundries?
- Which toolkits are used? (Server & Client)

Marvin Smit.
On Tue, 30 Aug 2005 02:38:10 -0700, sys
<sy*@discussions.microsoft.com> wrote:
I have a web method that returns a string. When I return a string that has a
carriage return and line feed in it ("\r\n") on the client side I only
receive a string including the line feed ("\n"). The carriage return
disappeared.
Thanks for any help.


Nov 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Alin Popovici | last post: by
2 posts views Thread by Alin Popovici | last post: by
2 posts views Thread by Andrew Chanter | last post: by
3 posts views Thread by Dinsdale | last post: by
reply views Thread by gheharukoh7 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.