Skip to content

Infragistics Community Forum / Desktop / Ultimate UI for Windows Forms / Multiline TextBox not dispalying carriage return properly

Multiline TextBox not dispalying carriage return properly

New Discussion
Travis
Travis asked on Dec 18, 2008 8:08 PM

Hi, my carriage return is stored in XML and saved to the database.  When the XML is loaded and the string is pulled… it sets the text field and NOT in edit mode, it displays fine… but when in edit mode it displays the little sideways rectangles indicating carriage returns.

 

Any idea what is going on here?  I have the multiline on, FYI.

Sign In to post a reply

Replies

  • 0
    Matt Snyder
    Matt Snyder answered on Dec 18, 2008 7:33 PM

    The UltraTextEditor uses a .NET TextBox when in edit mode; do you have the same problem when using a TextBox?  It's possible that you need to convert the carriage return to the Environment.Newline character, or whatever character the TextBox recognizes (which I think is "\r\n").

    -Matt

    • 0
      Travis
      Travis answered on Dec 18, 2008 8:07 PM

       I haven't tried that.

       I was hoping that there was a property to set for this feature.  So every multiline text box I have to convert the incoming text?  Ick…

       

      • 0
        Travis
        Travis answered on Dec 18, 2008 8:08 PM

         THis works for me:

        strWhatever.Replace("\n", Environment.NewLine)

  • You must be logged in to reply to this topic.
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Travis
Favorites
0
Replies
3
Created On
Dec 18, 2008
Last Post
17 years, 3 months ago

Suggested Discussions

Created by

Created on

Dec 18, 2008 8:08 PM

Last activity on

Feb 20, 2026 11:29 AM