Webgrid 9 Fixed Height IE11

1 reply. Last post: July 30, 2015 3:13 AM by Yudi
Tags :
  • New Discussion
  • New Question
  • New Product Feedback

Seeing that I cannot get a response from Intersoft support, I'll post my issue here.  Basically, I have recently upgraded to Webgrid 9 (9.0.7200.1) and WebUI Framework 3.0.5000.  I have a number of fixed height Webgrids, which render correctly in the latest versions of Firefox, Chrome, and IE10, but not in IE11.  Under IE 11, the HTML of the grid renders as it does for all other browsers, however the client script which runs on page load detects the browser as "IE" and therefore runs client script which fails trying to set the height of dvTB_Webgrid1_, based on the height of the Webgrid1_of div.  You can see an example here:

https://webdev.fultonhomes.com/phindall/selectedoptions2/viewoptions.aspx?proj=ff00t&unit=0052

As you can see, I'm running under the HTML5 DOCTYPE and with RederingMode="HTML5".

Here's a little more detail:

My investigation reveals the following is the problem.  Under RenderingMode="HTML5" Webgrid renders a series of nested DIVs, with the highest level one being Webgrid1_of.  On page load, Webgrid runs through a series of client scripts to set up the grid layout.  Among those is a function called AssignInitialHeight.  AssignInitialHeight detects both IE10 and IE11 as “IE” (IS.ie==true) and sets forth to manually calculate the height of dvTB_Webgrid1_.  Within this function, another function (WGUIEngine.OnGridResize) is called.  Within OnGridResize, the function WGUIEngine.GetTableBodyHeight(b) is called with b=dvTB_Webgrid1_.    GetTableBodyHeight looks to the style of the parent div of the Webgrid (Webgrid1_of), to get this height.  On IE10, this returns the height value that was set when instantiating the WebGrid:

<ISWebGrid:WebGrid ID="WebGrid1" runat="server" width="730" Height="470" RuntimeLicenseKey="0LAC4-1B0D-OTNB8" RenderingMode="HTML5" >

However, under IE11 the function returns NaN.  Looking at the rendered HTML reveals why. . .

IE 10: <div id="WebGrid1_of" style="position:relative; ;height: 470px;width: 730px;">

IE 11: <div id="WebGrid1_of" style="position:relative; ">

Interestingly, under Chrome and Firefox, the “Webgrid1_of” div renders as it does in IE11, but of course the client ssript does not detect these as “IE.”

It appears from the above that this may be a conflict between the server-side grid rendering and the client script.  Under IE11, the server side renders the grid as it does for all other modern browsers.  However, the client side script detects IE11 as “IE” and therefore runs IE-specific script, which fails.

All times are GMT -5. The time now is 1:35 AM.
Previous Next