How I can display HTML formatted text in .Net TextBox?
4 Answers
Not possible
check this : http://www.freetextbox.com/
or
http://www.codeproject.com/KB/aspnet/RichTextBox.aspx
But you can go for the HTML editors like fck editor to do so.
Comments
You might also look into extending the TextBox control to allow HTML syntax formatting and highlighting. I don't know how difficult or easy this might be, but it would certainly be an interesting learning experience. If you're not looking to "roll your own" then probably one of @Pranay's suggestions is your best bet.
Comments
If you dont have to EDIT the displayed formatted text, its easy use a literal control,
but if you have to be able to change the info, you would need a control that can handle html.
I use FreeTextBox, but there are many.
Be aware of the dangers of allowing HTML to be edited in your page.... this is a weakspot that hackers love...
(you have to set validaterequest=false in each page that contains a HTML edit control
Bert