Take the 2-minute tour ×

I've tried Infragistics on this but they don't seem to understand what I am asking and it takes days to get an answer so please help!

I need to place an Infragistics web grid into either a div or a table cell. The grid must size to fit the div or cell. If there is too much data to display, I need the grid to do its magic and add its own scrollbars.

So far I have achieved this using javascript and resizeing every time the browser window resizes. Unfortunately when refreshing the page (using AJAX), the grids resize themselves to their default sizes for a second before correcting but this is not acceptable to the customer (or me for that matter).

It is irritating that width=100% works but height=100% does not. I find that it just extends out of the div or table (not even resizing the div, just expanding out of it).

I have tried the KB article that sets the height and width to 100% and the frame custom rules to table-layout:auto but this doesn't work.


I created a test project with a 500px tall table, two rows (each 50% height) and two cells per row to give a 2 x 2 grid. If I set the Infragistics grid height to 100% within a cell, it fits perfectly until you bind it to data. It then extends, making the table more than 500px high.

I tried putting a 100% x 100% div in one of the cells and the grid in this. Then the table stays the correct size but the grid grows in height by the size of a row and extends out of the div and the cell :-(

I am starting to wonder if the Infragistics web controls are as good as they should be. They certainly don't seem to be as good as the Windows versions.

share|improve this question
Set your div to a specific height, not a % with overflow-y set to scrollable. –  JoshBerke Jan 16 '09 at 17:08
I need the grid to resize automatically so a specific height isn't appropriate. Even so, when you set a specif height, the grid still doesn't honour it. –  Baffled by ASP.NET Jan 29 '09 at 9:24

4 Answers 4

Have you tried only specifying width=100% and leaving the height specification off of the grid completely?

Another thought is placing the grid on an asp.net panel and placing the panel in the div or table cell.

share|improve this answer
I tried that. When the grid data is smaller (less rows) than the div/cell it is in, the horizontal scrollbar for the grid appears to high up the page. Also, if there are too many rows, they extend past the div/cell. –  Baffled by ASP.NET Dec 30 '08 at 17:37
I stumbled onto this KB from Infragistics that talks about dynamically resizing row height. It calls the InitializeLayout using javascript. You may be able to use this same technique to resize the grid accordingly. devcenter.infragistics.com/Support/… –  Tyler Dec 30 '08 at 17:43

Have you tried it in an empty project without any user controls , masterpages and inheritance ? If there where no possible properties to do that , I think you can do this job by conditional code .

share|improve this answer

I had a simillar issue with ComponentArt's grids, and If I understand you then maybee this will help.

What I had to do was limit the height of the grid by putting it in my own Div, which had overflow-y scrollable. So I had this:

Do not specify a height on the grid at all.


You need to set a set a specific height on your div I think.

<table style="height:500px">
      <td>Cell 1</td>
      <td>Cell 2</td>
         <div style="height:400px;overflow-y:scrollable"> <ingragists...>
       <td>Cell 3</td>
share|improve this answer
Unfortunately that doesn't work either. On the Infragistics control the grid ends up absolutely positioned and won't scroll within the div. Even if it did, it would hide the column headers, which would not be acceptable to the customer. –  Baffled by ASP.NET Jan 16 '09 at 11:28
Hah well keeping the grid headers is a whole other beast. I've managed to get my CA grids to live inside a fixed height scrollable div, and if you look at my issue tracker you'll find one in there to keep the column headers fixed. –  JoshBerke Jan 16 '09 at 17:06
up vote 0 down vote accepted

I resolved this in the end by removing the doctype from the ASP.NET page. It seems that the way that the grid is laid out does not work properly with IE in standards mode. It looks like mainly an IE problem.

Infragistics have said that they are working on a new grid that doesn't have these problems but unfortunately it does not yet have the flexibility of the standard grid.

share|improve this answer

Your Answer


