Don't set any height attribute for the grid and it will align the rows
nicely. Instead, put the grid in a <divand set the height for the div. You
can create an impression that the grid fills up the whole height of the
<diveven if it has less than 10 records by setting the same background
color for the grid and the <div>.
--
Eliyahu Goldin,
Software Developer
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin http://usableasp.net
"Julia B" <Ju****@discussions.microsoft.comwrote in message
news:B7**********************************@microsof t.com...
Hi, I'm working with .net version 1.1.
I've got a datagrid on a webform that my users want a fixed height, which
is
fine. It can contain up to 10 records. If there are 10 records then it's
fine
and looks very nice. However if there is only 1 record (or just a few)
then
it looks daft, because the records aren't vertically aligned at the top.
I can't find a vertical alignment property for a datagrid. Is there a way
of
working this so that the records will always be placed at the top?
Thanks
Juia