Link to home
Start Free TrialLog in
Avatar of SQLBI1
SQLBI1

asked on

ASP.NET & IE8 - Div Container/Gridview CSS Problem?

Hi All -

I have a simple page with a few div containers that contain gridviews. In IE6 these render just fine, with the div container expanding as the gridview size increases (additional rows). However, in IE8 these containers do not increase in size with the gridview, and the gridview just grows straight down outside of the box. Any ideas?

Thanks
Avatar of Carl Tawn
Carl Tawn
Flag of United Kingdom of Great Britain and Northern Ireland image

Try adding an overflow:auto; style to the DIV.
hi! you may try to add style of your div.

<div style="display:table-cell;"> </div>


you may try other display properties;
Avatar of SQLBI1
SQLBI1

ASKER

Hi - thanks for the replies. overflow: auto did get me closer but not quite there. Now, the div remains a fixed size and shows scroll bars, but I need the whole div to expand with the gridview. Code below:

#contents
{
    margin-top: 0px;
    margin-right: auto;
    margin-left: auto;
    margin-bottom: 15px;
    width: 800px;
    padding: 20px 20px 20px 20px;
    background-color: #FFF;
    color: #000;
    border-top: solid 2px #1F417E;
    border-left: solid 1px #1F417E;
    border-right: solid 1px #1F417E;
    border-bottom: solid 5px #1F417E;
    border-color: #1F417E;
    overflow: auto;

}
ASKER CERTIFIED SOLUTION
Avatar of Carl Tawn
Carl Tawn
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of SQLBI1

ASKER

Carl, you were right - looks like I simply had a parent tab panel passing a fixed height. For some reason the property was always ignored by IE6 and I never noticed until the upgrade to IE 8 (hey, IE 8 actually works correctly with at least that property!). Thanks all for the comments.