11/28/2011

How To Set Dojo Timeout for Partial Updates and AJAX Calls

I recently had a hard time searching for a possibility to set the default for a call done by an XPage client side script. XPages-Dojo default is somewhere around 6 seconds (infinite for normal dojo), which is just not enough in some places (be sure to include a loading bar or dojo standby to signal the user you are still doing something for them in the backend). After some research i found this link, whick is exactly what i needed, and now im reblogging it here to give it some more keywords for you to find it if you need it (because i did not).

The solution is: just add the following line to your XSP.addOnLoad() function:

XSP.submitLatency = 600 * 1000; // latency in milliseconds