dhtmlxGrid inside dhtmlxWindow problem

I have a dhtmlxWindow with some content and some of that is a dhtmlxGrid.
In IE the grid shows up nicely as supposed to, but in both Firefox and Chrome the grid doesn’t show as supposed to.

Here is the function that initiates the grid:

[code]function initGrid()
{
var grid_columns = " ," +
Emailadresse,” +
Type,” +
Interval,” +
Foldere,” +
 ”;

        mygrid = new dhtmlXGridObject('notification_grid');

        mygrid.setImagePath("dhtmlxGrid/codebase/imgs/");
        mygrid.setHeader(grid_columns);
        mygrid.setInitWidths("0,140,50,120,*,26");
        mygrid.setColAlign("left,left,left,left,left,center");            
        mygrid.setColSorting("str,str,str,str,str,str");
        mygrid.setColTypes("ro,ro,ro,ro,ro,ro");
        mygrid.enableMultiselect(false);

        mygrid.init();

        mygrid.setSkin("dhx_skyblue");
    }[/code]

Here is the grid div:

[code]

Mine Mail Notificeringer
[/code]

Here are the results for the 3 browsers:

Internet Explorer

Firefox

Chrome

To me it looks like a stylesheet problem but I don’t know what is causing it.
Can you tell me what to do to fix this?

/Aidal

You are init grid while window is not shown yet, right ?

In such case after showing the window, call the next command

grid.setSizes();

It will force resizing of grid.

Hmm no…

This happens first:

[code]var win = dhxWins.createWindow(‘win_manage_mail_notifications’, 0, 0, 580, 556);

dhxWins.window(‘win_manage_mail_notifications’).setText(‘Mail Notificeringer’);
dhxWins.window(‘win_manage_mail_notifications’).denyResize();
dhxWins.window(‘win_manage_mail_notifications’).button(‘park’).hide();
dhxWins.window(‘win_manage_mail_notifications’).button(‘minmax1’).hide();
dhxWins.window(‘win_manage_mail_notifications’).button(‘minmax2’).hide();
dhxWins.window(‘win_manage_mail_notifications’).setModal(true);
dhxWins.window(‘win_manage_mail_notifications’).center();
dhxWins.window(‘win_manage_mail_notifications’).keepInViewport(true);
dhxWins.window(‘win_manage_mail_notifications’).setIcon(‘App-mailreminder-icon.png’, ‘App-mailreminder-icon.png’);
dhxWins.window(‘win_manage_mail_notifications’).attachURL(‘ldd_manage_mail_notifications.html’);[/code]
The attached html page contains the previous code.

An event handler on window-content-loaded performs an async call to a service which retrieves the rows for the grid and when that call returns, the grid is populated with the parse() method.

If I insert the mygrid.setSizes() after the parse() call (which would be the proper location I guess) nothing changes - the results are still as shown on the pictures.

Any ideas?

I can’t reconstruct the same issue locally.
Do you have any kind of sample or live demo where issue can be reconstructed?
( you can PM the details )

There are 2 possible scenarios when similar issue can occur

  • usage of auto-width in grid and incorrect column width
  • setting incorrect width to the grid’s container

I have PM’ed you the info.

Any luck ?

Problem caused by the page layout. One of elements surrounding the grid has zero width, and because of that grid takes zero height itself.