Controlling datagrid column width when there are no records.

W

weaklingX

I have several datagrids stacked one above the other that are all sized
to 95% width. Each grid has two columns, with the second columns'
widths set to 70px (so the first column's width is not set and it flows
to fit the rest of the grids with). This works great for my needs and
looks good with how I am using the grids with one exception: When
there are no records in one of the grids, that grid's second column
ignores the 70px width and does whatever it wants. Is there any way to
force the column size even when there are no records? I know there are
other options but would like to do it this way if possible.

Thanks.
 
D

dkode

You could probably do this through CSS, although i am not too
profecient in CSS design, I would use a 1x1 transparent gif, normally
called "spacer.gif" and you can then set its width to the desired size,
upon finding there are no rows for that datagrid.

That would be the easiest way IMO.

hope this helps!

Sean
 

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,995
Messages
2,570,228
Members
46,818
Latest member
SapanaCarpetStudio

Latest Threads

Top