Groups | Blog | Home
all groups > asp.net building controls > may 2005 >

asp.net building controls : The nowrap Property of TD Tags


Steve Goodyear
5/20/2005 9:12:03 PM
The first is XHTML and second is HTML 4 compatible.

Cheers,
Nathan Sokalski
5/20/2005 11:49:11 PM
I want to create TD tags with the nowrap property. I have a user control
which sets the Wrap property of a TableCell to False when dynamically
creating a table as follows:

cellCurrButton.Wrap = False

When the code is run, this creates a TD tag that looks like the following:

<td nowrap="nowrap"></td>

However, when I edit the properties of a TD Tag created in Design, there is
a property called nowrap which when set to True creates a TD Tag that looks
like the following:

<td nowrap></td>

I prefer the second way because it is shorter and I also believe it is the
correct HTML. However, because the TableCell object does not have this
property, I cannot use it when creating generated TableCells. Why are these
two outputs so different? Thanks.
--
Nathan Sokalski
njsokalski@hotmail.com
http://www.nathansokalski.com/

AddThis Social Bookmark Button