473,396 Members | 1,599 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Datagrid with fixed height

Mau
I have a question:
I have a datagrid with paging (4 elements for page), header and footer
I set a fixed height: 600px

So the situation is (in a page with 5 elements)
6 rows (header + 4 elements + footer)
every with fixed height 100px, and this is ok

but in a page with 1 element (for example) I have
3 rows (header + 1 element + footer) every row is 200px height

Instead I would like to have: header 100px + 1 row 100px + 300px di blank
space + footer 100px
That is row, header and footer with fixed height and a blank space before
the footer
to fit the total fixed height.

What's the solution?
Can someone help me?

Thanks

M
Nov 18 '05 #1
3 2126
Hi Mau,
Keep a div in the page and keep the datagrid inside the div and specify the
height to the div instead of the datagrid.
HTH
srini

"Mau" wrote:
I have a question:
I have a datagrid with paging (4 elements for page), header and footer
I set a fixed height: 600px

So the situation is (in a page with 5 elements)
6 rows (header + 4 elements + footer)
every with fixed height 100px, and this is ok

but in a page with 1 element (for example) I have
3 rows (header + 1 element + footer) every row is 200px height

Instead I would like to have: header 100px + 1 row 100px + 300px di blank
space + footer 100px
That is row, header and footer with fixed height and a blank space before
the footer
to fit the total fixed height.

What's the solution?
Can someone help me?

Thanks

M

Nov 18 '05 #2
Mau
> Keep a div in the page and keep the datagrid inside the div and specify
the
height to the div instead of the datagrid.


ok, but in this case the footer move up and down if the
number of the elements of the datagrid page change
I would like to avoid this...

thnks

M
Nov 18 '05 #3
in that case you can try setting the ItemStyle, HeaderStyle and FooterStyle.
HTH
srini

"Mau" wrote:
Keep a div in the page and keep the datagrid inside the div and specify

the
height to the div instead of the datagrid.


ok, but in this case the footer move up and down if the
number of the elements of the datagrid page change
I would like to avoid this...

thnks

M

Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Stephen | last post by:
I have a datagrid and i'm trying to fix the width of one of the columns to be exactly 300px. My problem is that one of the records fields(CompanyName) is really long and has no spaces so it...
1
by: Lalit Bhatia | last post by:
how can we fix first column in DataGrid? Regards, Lalit Bhatia
0
by: Lalit Bhatia | last post by:
thanks for the answer but I need it for windows forms. I have a desktop application where I need to implement this. -- Regards, Lalit Bhatia "Mona" <mona@discussions.microsoft.com> wrote in...
7
by: Matthew Wieder | last post by:
Hi - I have a datagrid that has a black header and the rows alternate white and gray. The problem is that until items are added to the grid, the grid appears as a large black rectangle, which is...
2
by: Carlo Marchesoni | last post by:
I have a very basic question using the DataGrid. What I want to achieve is controlling the size of it (specially the height of the rows). The DataGrid adjusts the row size according to the amount...
0
by: Mau | last post by:
Hi, I've a datagrid with fixed height when I have few rows the height of single rows increase to fit the fixed height of the grid. I would like to have a blank space before the footer and fixed...
2
by: Sam | last post by:
hi folks, 1. how to set column width in datagrid server control? 2. how to set row height in datagrid server control? 3. how to display scroll bar in datagrid server control? thanks,
2
by: Charleees | last post by:
Hi all, I have a DataGrid with Template Columns..... There are LAbels,Linkbuttons in the Single Row.. I have to set the Constant Column width for those Template Columns in Grid... Wat...
6
by: slinky | last post by:
I found the following code to transfer datagrid data to an Excel file. Is this written in C#?... I'm a vb.netter. I'm just not sure where to place the code to experiment on it. Should I place it in...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.