Hiding a column

E

Eliyahu Goldin

Uri,

This is the way:

<asp:BoundColumn DataField="myField">
<ItemStyle CssClass="Invisible"></ItemStyle><HeaderStyle
CssClass="Invisible"></HeaderStyle>
</asp:BoundColumn>

The style:
..Invisible

{

display:none;

}


Eliyahu
 
U

Uri

Hi,

I'd like to have a bound column contain a hidden field. When I set a
column's Visible to false, the column
is not rendered at all and I cannot access it programmatically after post
back.

I've tried leaving the column visible and setting its width to 0px but the
column still shows on the page.

The best solution I've found is to stick a testbox into one of my existing
columns and set its width to 0px.

Does anyone know of a more elegant way to do this?

Thanks,
urig.
 

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

Forum statistics

Threads
473,731
Messages
2,569,432
Members
44,835
Latest member
KetoRushACVBuy

Latest Threads

Top