468,512 Members | 1,449 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,512 developers. It's quick & easy.

New Line character storage in ntext field in SQL 2000

59
Hi there,
I have a multi line text box in a data entry form. The data entered in this field is being stored as ntext column in a table.
This data is visible in other form in DataGridView. Where the newline character is replaced by ugly, obnoxious "squares". I remember having used this with oracle blob column where it did not create a porblem.
Agagin when this fetched in a multiline textbox for editing purpose it displays "squares".
Hw do I handle this. I tried googling but not much to my rescue. Any pointers or ideas would be appreciated.
Thanks for your time.
Jan 25 '10 #1
7 3275
ThatThatGuy
449 Expert 256MB
have you tried it with nvarchar,varchar....
Jan 25 '10 #2
babai28
59
While googling I found that even these fields don't help.
Jan 25 '10 #3
Plater
7,872 Expert 4TB
I store newlines all the time in text and varchar and don't have any issues with squares
Jan 25 '10 #4
tlhintoq
3,525 Expert 2GB
It could be your choice of font.
For example I use a font called "crisp" which is deliberately designed as a programmer's font with lines through the zeros and newline characters appear as a tiny NL

Try changing your font to something standard like Arial and see if it still appears that way.
Jan 25 '10 #5
Plater
7,872 Expert 4TB
You should not see the boxes in a field that allows new lines (like a multiline textbox)
Jan 25 '10 #6
tlhintoq
3,525 Expert 2GB
'should' being the operative word.
I don't know much about how databases can convert text. Is it possible the newline is being changed into something else? A newline in one OS is not necessarily a newline in another OS.
Can you run a debug version of your application and look at the actual bytes of the data and confirm it is truly the newline you expect and not just a carriage return for example.
Jan 25 '10 #7
babai28
59
Hi All,
Thanks for your replies. The problem is solved
by setting the datagridViewColumn wrap mode property to true.
Thank you once more.. all of you..
Jan 27 '10 #8

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

1 post views Thread by Bill | last post: by
5 posts views Thread by Kuljo | last post: by
2 posts views Thread by Sileesh | last post: by
reply views Thread by NPC403 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.