space in column data

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ananda Vardhan
    New Member
    • Oct 2011
    • 1

    space in column data

    I have data like this in a column
    "Test Sample "
    Spaces between test and sample words and after sample. When i retrieve this in a multiline textbox it displays small squares for spaces which is weird.
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    That means they're not spaces. They are unprintable characters and different programs display them in different ways.

    Comment

    • arie
      New Member
      • Sep 2011
      • 64

      #3
      As @Rabbit said, they're probably not spaces. Find out what those characters are

      Code:
      char strangeChar = '?'; 
      int charcode = strangechar; // decimal code of character '?'
      (here's the ascii table: http://www.asciitable.com/), and replace them before displying
      Code:
      textToDisplay = yourString.Replace (oldchar, newchar);

      Comment

      Working...