GetText(LineEndStyle.CarriageReturnNewline)?

SyntaxEditor for Windows Forms Forum

Posted 14 years ago by JoeP - Software Design Engineer, Microsoft
Avatar
Hi;

When I use SyntaxEditor.Document.GetText(LineEndStyle.CarriageReturnNewline), I'm only getting the newline characters. We're pasting the text after copying from Query Analyzer, using the default context menu.

I need both, any thoughts?

Thanks

Comments (3)

Posted 14 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Joe,

When I test it in the sample app by doing this, it seems to return the correct result:
editor.Document.Text = "a\nb";
string text = editor.Document.GetText(LineEndStyle.CarriageReturnNewline);
After the last line I break and examine the variable "text" with the VS.NET debugger and it has this value "a\r\nb", which is what it should have.

If you can tell us how to duplicate the issue in the sample project, please post how. It appears to be working ok from our end.


Actipro Software Support

Posted 14 years ago by JoeP - Software Design Engineer, Microsoft
Avatar
Well, after further testing, it appears that it's our data layer that's parsing out the character while passing it to the db.

Sorry for the false alarm (btw, you guys are great!).

Thanks
jp
Posted 14 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
No problem Joe... glad you got it working!


Actipro Software Support

The latest build of this product (v2018.1 build 0341) was released 6 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.