Posted 10 years ago by John.liu
Version: 12.1.0132

When I used that code in silverlight with IronPython.

xaml:<app:ButtonEx Content="PageData传值" ActionParam="a=['ss']; \r\n b=Dicationary[str,object]()\r\n" />
editor.Document.InsertText(ActiproSoftware.Text.TextChangeTypes.DuplicateLine, 0,code); 

the result is "a=['ss']; \r\n b=Dicationary[str,object]()\r\n"

why "\r\n" doesn't effect.....

I hople the result is :



[Modified 10 years ago]

Comments (3)

Answer - Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA

Hi, do you mean that you are putting \r\n in your XAML?  If so, XAML doesn't recognize those character sequences as special characters.  Many of our samples show how you can build multi-line document text in XAML.

Or alternatively if you mean you are trying to set it in code, it's likely that your string didn't get the \r\n characters translated to real CR/LF characters.  You should debug the string to make sure.  If you pass real CR/LF characters to SyntaxEditor, it will be converted to a line terminator.

Actipro Software Support

Posted 10 years ago by John.liu


I do it with code like:

code="a=['ss'];[r]b=Dicationary[str,object]() [r]";


then can build multi-line document text in silverlight

Posted 10 years ago by John.liu

thanks for your help.

The latest build of this product (v2018.1 build 0233) was released 3 years ago, which was after the last post in this thread.