Inserting text into TableCell at runtime

J

Jurjen de Groot

I want to show a variable length field within a cell in a table. <TD>
....here... </TD>

I'm not sure how to do that, the information is stored in a class property
Org.CVtext

I can't use a textbox because it might not show all text and when printing
this page the info is incomplete. I've tried using a label but then all
VBCRLF aren't rendered and the text is just one long sentence. There must be
some way to show this....


Any help is greatly appreciated.


Jurjen de Groot
Netherlands
 
X

Xavier MT

Quick workaround, im sure there are better solutions but you can use html
tags
for example with a label
Label1.Text = "first line " & vbnewline & "second line"

Change it to

Label1.Text = "first line <br> second line"



Just use a replace function if only crlf is your problem



xavier
 
K

Kevin Spencer

In HTML, CRLF characters are just "white space" characters, and are not
rendered as line breaks. Line breaks in HTML are rendered via the "<br>"
tag. So, if you want your line breaks in there, you need to replace them
with "<br>" tags. You can do this with the String.Replace() method.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
http://www.takempis.com
Neither a follower nor a lender be.
 
X

Xavier MT

That's what I said just that Kevin explained it the way it should be
explained :p

Just trying to help and I need some help
 

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

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top