Call method sendData three times in a button onclick, only o

I spent three days had not solve this problem, pls help me, thanks all,



I have three dhtmlxgrid in a pege. Only the last one requet was down when I sent data from the method of sendData()

example:



g1 = new dhtmlXGridObject(“grid1”);

g1.setColumnIds(…);

g1.setHeader(…);

pd1 = new dataProcessor(url);

pd1.enableDataNames(true)

pd1.setUpdateMode(“off”);

pd1.init(g1);



g2 = new dhtmlXGridObject(“grid2”);

g2.setColumnIds(…);

g2.setHeader(…);

pd2 = new dataProcessor(url);

pd2.enableDataNames(true)

pd2.setUpdateMode(“off”);

pd2.init(g2);



g3 = new dhtmlXGridObject(“grid3”);

g3.setColumnIds(…);

g3.setHeader(…);

pd3 = new dataProcessor(url);

pd3.enableDataNames(true)

pd3.setUpdateMode(“off”);

pd3.init(g3);



// submit data

button1.onclick = function submits(){

pd1.sendData();

pd1.sendData();

pd1.sendData();

}









You have 3 instance of DataProcessor on your page. Probably you should use:

button1.onclick = function submits(){
pd1.sendData();
pd2.sendData();
pd3.sendData();
}


sorry, I was wrong.  I was use like following,



button1.onclick = function submits(){
    pd1.sendData();
    pd2.sendData();
    pd3.sendData();
}



but only the last one requet was down when I sent data from the method of sendData.




 



 



 

Please try to attach debug version of dhtmlxdataprocesso.js file. So you will be able to check what responced does DataProcessor send to the server side.
Please find more information here dhtmlx.com/dhxdocs/doku.php?id=d … debug_mode