String xml = req.getParameter("grid_xml") is null

Hello,

I have an issue which seems to be reproduced only on some cases which lead to trigger a nullPointerException when doing “xml = URLDecoder.decode(xml, “UTF-8”);.”

Is there any reason it can work on some cases and not on others.

  • Special characters ?
  • Volume of datas ?

Thanks in advances for your replies.

I am using the 3.6 version of DHTMLX.
Combining javaScript and Java

It seems to be related to the number of cells ans so maybe the length of grid_xml. (I have around 23400 cells aka rows number * columns number)

And an other note, I have seen that the xml was made using lot of "+= "to concatenate.

Array.join may be more performant ?

Thanks

I reproduced the problem on IE 9 (Quirks mode) .

There is no problem when assigning the value to the input “grid_xml” (cf italic code)
But when it is submitted, it comes null on the server part (Java,Tomcat) if it has too much characters (only in IE) ~43000 characters

document.getElementById(uid).firstChild.value = encodeURIComponent(xml_top(mode).replace("\u2013", “-”) + xml_body() + xml_end());
document.getElementById(uid).submit();

So it is maybe not realated to the dhtmlx component.

Does soemone know if there is a parameter to change which would avoid this behavior ?

I’m seeing this as well, are there any suggestions for workaround?

Looks like this was fixed in
forum.dhtmlx.com/viewtopic.php? … ull#p65270

But this seems like a very old file… is there a fix that works on v36?

Hi,

You are using a rather old verson of toolkit.
The latest version of DHTMLX (5.x) already includes all the same fixes

I can share the related codebase from the latest version ( it will not differ much from the above file ). Please beware that it will be file from version 5.x, and while it must work correctly with older version, it never was tested with 3.6

files.dhtmlx.com/30d/77ac559be4 … _export.js