TextBoxes created by "CreateWindowEx(WS_EX_CLIENTEDGE, "EDIT", "", ES_MULTILINE.." require \r\n for a new line. im redirecting my stdoutput into that textbox, which uses just '\n' to indicate a new line. and im not willing to replace all '\n' with '\r\n' isn't there a way to let '\n' beeing a newline in textboxes?
thx
-
\r\n is not a new line. It is a carriage return + new line. They are different things. It probably means more to people who work in the console world though because you can go to a new line without shifting back to character position 1.
From Joe Philllips -
I'm pretty sure what you're asking is impossible (i.e. there's no magic setting to make Windows edit controls accept Unix-style newlines).
5andr0 : alright, thanks for letting me know. so i really have to replace all the \n with \r\n :/From codebolt -
Not sure what language you are using, but why not just do this (VB.NET Example):
TextBox1.Text=TextBox1.Text.Replace("\r\n","\n")
That should replace all the "\r\n" occurences with just "\n"
From icemanind
0 comments:
Post a Comment