TableCell Text Wrapping Problem!

A

Amelyan

If I have spaces in my Text property of Label, and I add it to TableCell, it
wraps at spaces. E.g.

Label lb = new Label();
lb.Text = "Hello, World!"
TableCell cell = new TableCell();
cell.Controls.Add(lb);


The resulting TableCell html render will look like this
_______
| Hello, |
| World! |
|_______|

However if I don't have spaces in my lb.Text, "Hello,World!", the resulting
TableCell html render will look like
___________
| Hello,World! |
|___________|

with "World!" written on new line. How can I disable this line wrapping for
Text which contains spaces?

Thank you,
-Amelyan
 
M

Mythran

Amelyan said:
If I have spaces in my Text property of Label, and I add it to TableCell,
it wraps at spaces. E.g.

Label lb = new Label();
lb.Text = "Hello, World!"
TableCell cell = new TableCell();
cell.Controls.Add(lb);


The resulting TableCell html render will look like this
_______
| Hello, |
| World! |
|_______|

However if I don't have spaces in my lb.Text, "Hello,World!", the
resulting TableCell html render will look like
___________
| Hello,World! |
|___________|

with "World!" written on new line. How can I disable this line wrapping
for Text which contains spaces?

Thank you,
-Amelyan

on the cell, add the nowrap attribute :)

Mythran
 

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,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top