troubleshooting Question

Convert ASP.NET Textbox.Text to HTML

Avatar of sleaveruk
sleaveruk asked on
ASP.NET
2 Comments1 Solution1621 ViewsLast Modified:
I'm using ASP.NET VB and I have a multiline text box. I then use HttpUtility.HtmlEncode before inserting it into a SQL table.

The question is, if for example someone wrote the following:

Line 1
Line 2
Line 3

If that is inserted it shows as Line 1 Line 2 Line 3 sois there anyway of converting the text into HTML so it would be :

Line 1<br />Line 2<br />Line 3
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 2 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros