div element taking up space

D

dave

I am hiding the contents of a table cell with
display:none like the following:

When I do this and while hidden the row still takes up
some vertical space. How can I best use div elements to
hide table row while not taking up and vertical space?

thx


<TR>
<TD><DIV id="div1"
style="display:none;">Something</DIV></TD>
<TD>
<DIV id="div2" style="display:none;">
<input
name="dgCompany:_ctl2:txtProjectNumber" type="text"
id="dgCompany__ctl2_txtProjectNumber" class="clsInput" />
</DIV>
</TD>
</TR>
 
A

Alessandro Zifiglio

cant you just set the display mode of the cell as none whereas to adding an
extra element into the the table cell and making that invisible.
 
M

MSFT

Hi dave,

I think you may set the table run at server side. In this way, you can hide
a row with following code:

table1.Rows[1].Visible =false;

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
 

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,057
Latest member
KetoBeezACVGummies

Latest Threads

Top