4 Answers
However, I am wondering if there is a way to put a custom button on the grid that can be used to control the java script to pause and start the auto refresh?
If you wish to auto reload grid at e.g. 2 min interval, you can call this JS code.
setInterval("jQuery('#list1').trigger('reloadGrid',[{page:1}]);",2000);
If you wish to start/stop it on some toolbar button, You need to refer:
– Add toolbar button: https://www.gridphp.com/demo/demos/appearance/toolbar-button.phps Line 122
– Enable / Disable timer: https://www.w3schools.com/jsref/met_win_clearinterval.asp
In case of any issue, Please share the code and I’ll recommend the changes.
Your Answer