Whitespace in datagrid webcontrol

R

Rik Sanchez

I have a datagrid with a header and pager.

what i want to do is have a fixed height for the header and pager
which i already now how to do.

What i cant seem to figure out is how to fix the size of all the items
in the datagrid and have whitespace under. For example my datagrid
can hold 5 entries per page but there are only two entries..What
happens is that the header and pager remain fixed but the items
stretch in height fill the whole space for items.. what i want to
happen is for the two entries to have a fixed height and for there to
be whitespace under the two entries and above the pager...

i would really appreciate any help on this. Thanks!!!
 
A

Alvin Bruney [MVP]

from the designer, adjust the size of the grid where you want it to be
during run-time, then remove the height property in the property pages. that
will prevent the grid from growing
 
R

Rik Sanchez

This doesnt seem to work. even if i set the height of the grid to
blank it still resizes during runtime depending on the number of lines
needed to display the data from the data set...if there are multiple
lines then the grid grows accordingly.

Alvin Bruney said:
from the designer, adjust the size of the grid where you want it to be
during run-time, then remove the height property in the property pages. that
will prevent the grid from growing

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Rik Sanchez said:
I have a datagrid with a header and pager.

what i want to do is have a fixed height for the header and pager
which i already now how to do.

What i cant seem to figure out is how to fix the size of all the items
in the datagrid and have whitespace under. For example my datagrid
can hold 5 entries per page but there are only two entries..What
happens is that the header and pager remain fixed but the items
stretch in height fill the whole space for items.. what i want to
happen is for the two entries to have a fixed height and for there to
be whitespace under the two entries and above the pager...

i would really appreciate any help on this. Thanks!!!
 
A

Alvin Bruney [MVP]

The reason it grows is because there is a height in there somewhere. If you
remove the height, there will be no value that it can stretch to.

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Rik Sanchez said:
This doesnt seem to work. even if i set the height of the grid to
blank it still resizes during runtime depending on the number of lines
needed to display the data from the data set...if there are multiple
lines then the grid grows accordingly.

Alvin Bruney said:
from the designer, adjust the size of the grid where you want it to be
during run-time, then remove the height property in the property pages.
that
will prevent the grid from growing

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
Rik Sanchez said:
I have a datagrid with a header and pager.

what i want to do is have a fixed height for the header and pager
which i already now how to do.

What i cant seem to figure out is how to fix the size of all the items
in the datagrid and have whitespace under. For example my datagrid
can hold 5 entries per page but there are only two entries..What
happens is that the header and pager remain fixed but the items
stretch in height fill the whole space for items.. what i want to
happen is for the two entries to have a fixed height and for there to
be whitespace under the two entries and above the pager...

i would really appreciate any help on this. Thanks!!!
 

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,781
Messages
2,569,615
Members
45,295
Latest member
EmilG1510

Latest Threads

Top