Invalid Argument error (IE)

I’m using an evaluation copy of dhtmlxSuite 2010 Rel.1 (DHTMLX 2.6) Professional edition build 100916(with IE9 fix applied).

I have a grid that loads,renders and works fine on Safari, Firefox and Camino… but when I point IE (7 or 8) I get an Invalid Argument found on codebase/dhtmlxgrid.js, line 77, character 93… which is in my case a var i variable for starting a loop - so the error must be somewhere else in that line.

Has any one experienced this problem before? Not sure if I have the latest built or if its an IE specific thing I’m encountering…

Such issue may occur if you have not specified widths for alignment for each column in grid.

That’s the weird thing… I have… All columns have a width associated with them.

I started to play with the data/XML to try to debug things out and this is what I found. I have a PHP script that spills out an XML with the rows and the HEAD config. The culprit seems to be the following code:

        <call command="attachHeader"><param> ,#text_filter,#select_filter, , , </param></call> 

Initially I thought the problem was a malformed XML on my part - but as part of my test I have concluded that is not… this is the problem I have:

mygrid.loadXML("test.xml");          //works just fine on all browsers
mygrid.load("db2xmlcopy.php");    //does not work in IE only - works on all others

I go to my webserver and do this:

php db2xmlcopy.php > test2.xml

mygrid.loadXML("test2.xml");          //works just fine on all browsers
mygrid.load("db2xmlcopy.php");    //does not work in IE only - works on all others

So the XML data is fine… as long as its not coming from a scripted output. I have even copy and pasted the whole XML into the PHP to be consumed by the grid. Does not work… as soon as I remove the command on the XML at the PHP - then it works fine.

So it seems (for some strange reason) that from a live script produces a different result that reading it from an XML file. I checked to make sure that I had no escape characters etc. That does not seem to be the problem. The XML also seems to be well formed (otherwise the piped output XML file would not had worked).

If I remove the attachHeader tag from the PHP… then the IE grid works just fine… so I know its the attachHeader on IE when streamed from a script… Not sure why that would make a difference.

Any thoughts on this?

Try to change attachHeader() call like this:

<afterInit> <call command="attachHeader"><param>&nbsp;,#text_filter,#select_filter,&nbsp;,&nbsp;,&nbsp;</param></call> </afterInit>

That seemed to work… :smiley:

Thanks Olga…