Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Jorge H on May 05, 2009 10:13
open dhtmlx forum
onAfterUpdateFinish AND onFullSync

Hi,

When I add the following code to my page, "onFullSync " does not run and "onAfterUpdateFinish" runs once per edited row.

    myDataProcessor.attachEvent("onFullSync",function(){alert("all rows updated")});
    myDataProcessor.attachEvent("onAfterUpdateFinish",function(){alert("single row updated")});

If I delete "onAfterUpdateFinish", "onFullSync" runs fine if I edit more than 1 row

Thank you.
Answer posted by Support on May 06, 2009 01:56
onAfterUpdateFinish executed each time when response from server side received, onFullSync will be executed after it, only if there is no more updated and not saved rows in grid. 
Both events works separately and only way how first can block second - is some js error inside custom code attached to onAfterUpdateFinish event.

Please try to replace alerts with some less obtrusive, for example console.log ( alert block process execution, and it possible that some other code in background can change state of dataprocessor ) 
Answer posted by Support on May 06, 2009 02:20
Updated version of dataprocessor.js attached to the post, please use it instead of original one - it will generate correct events in all cases
Attachments (1)
Answer posted by Jorge Herrera on May 06, 2009 08:14
Thank you, I works excellent, onFullSync runs after every transaction has been processed to the server via XML (insert, update, delete)