Is there a way to add HTML markup to a Textbox.Text property?

G

Guest

There has to be way to do this. Any help would be appreciated. Here is the
code.

txtReturn.Text = data[0] + Environment.NewLine +
data[1] + Environment.NewLine +
data[2] + Environment.NewLine +
data[3] + Environment.NewLine +
data[4] + Environment.NewLine +
data[5] + Environment.NewLine +
data[6] + Environment.NewLine +
"<bold>Phone: </bold>" + data[7] + Environment.NewLine +
"Territory: " + data[8];
 
M

Marina Levit [MVP]

A textbox is not capable of rendering HTML. You would have to put HTML into
a div or an element like that. You can have a DIV that is editable, so it
will look a lot like a textbox.
 
R

Ray Booysen

What you're looking for is the literal control. This will do exactly as
you require.

Regards
Ray
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,769
Messages
2,569,577
Members
45,052
Latest member
LucyCarper

Latest Threads

Top