I have a set of 10,000 records displayed in a grid with paging, 50 rows per page. I use dunamic loading.
There is a button called “Save All” on the screen, whenever user click this button function fnc_save_all() will be triggered. I want to save all the data (in this case 10,000 records) into another table of my choice.
But strange things happen, only 50 records are saved, the rest of the data not saved at all, seems like only the first 50 records from first page are saved. Why is this happen? Anybody can help me?
mygrid = new dhtmlXGridObject('gridbox');
mygrid.setImagePath("dhtmlx/dhtmlxGrid/codebase/imgs/");
mygrid.setSkin("dhx_skyblue");
mygrid.init();
mygrid.enablePaging(true, 50, 10, "pagingArea", true, "infoArea");
mygrid.setPagingSkin("bricks");
mygrid.loadXML("load.asp");
myDataProcessor = new dataProcessor("update.asp");
myDataProcessor.setTransactionMode("POST", true);
myDataProcessor.setUpdateMode("off");
myDataProcessor.init(mygrid);
function fnc_save_all(){
mygrid.forEachRow(function(rowId){
myDataProcessor.setUpdated(rowId, true);
})
myDataProcessor.serverProcessor = 'update.asp';
myDataProcessor.sendData();
}