469,636 Members | 1,929 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

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

Textbox Carriage Return

Using ASP.Net and VB.net

I have textboxes (<asp:textbox id......>) in which the user will be entering
paragraphs.
They are multiline (several rows and several columns).
The carriage returns that the user puts in (return/enter key) do not show up
when the data is retrieved. It is one long line.
Is there any way to make the user's paragraph divisions show up in the
report?

May 17 '07 #1
2 16847
Keep in mind, the text they are typing is plain ASCII text. It includes
line-breaks but they're ASCII text linebreaks. That means when you retrieve
them and display them in a web page it's meaningless because they aren't
HTML line breaks. You just need to do a Replace() on the text string and
replace the carriage return linefeed with a <br /element. I believe in
VB.Net this is a vbCrLf for both a carriage return and linefeed. Pass this
to the replace as Replace(vbCrLf,"<br />")
--
Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

"dancer" <da****@microsoft.comwrote in message
news:u5**************@TK2MSFTNGP02.phx.gbl...
Using ASP.Net and VB.net

I have textboxes (<asp:textbox id......>) in which the user will be
entering paragraphs.
They are multiline (several rows and several columns).
The carriage returns that the user puts in (return/enter key) do not show
up when the data is retrieved. It is one long line.
Is there any way to make the user's paragraph divisions show up in the
report?

May 17 '07 #2
YEA!!! It works!
Thank you.
"Mark Fitzpatrick" <ma******@fitzme.comwrote in message
news:uc**************@TK2MSFTNGP06.phx.gbl...
Keep in mind, the text they are typing is plain ASCII text. It includes
line-breaks but they're ASCII text linebreaks. That means when you
retrieve them and display them in a web page it's meaningless because they
aren't HTML line breaks. You just need to do a Replace() on the text
string and replace the carriage return linefeed with a <br /element. I
believe in VB.Net this is a vbCrLf for both a carriage return and
linefeed. Pass this to the replace as Replace(vbCrLf,"<br />")
--
Hope this helps,
Mark Fitzpatrick
Former Microsoft FrontPage MVP 199?-2006

"dancer" <da****@microsoft.comwrote in message
news:u5**************@TK2MSFTNGP02.phx.gbl...
>Using ASP.Net and VB.net

I have textboxes (<asp:textbox id......>) in which the user will be
entering paragraphs.
They are multiline (several rows and several columns).
The carriage returns that the user puts in (return/enter key) do not show
up when the data is retrieved. It is one long line.
Is there any way to make the user's paragraph divisions show up in the
report?


May 17 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by Paddy | last post: by
1 post views Thread by VMI | last post: by
1 post views Thread by fd123456 | last post: by
3 posts views Thread by HockeyFan | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.