Forum
00:15
30/03/2009
Hi Tony,
Is there an option to allow auto refreshing of the grid instead of having users to manually refresh it? Our data at the server end changes from time to time and we like the clients to refresh every x time period without user intervention.
We happened to see a working example HERE under the”Examples” tab. Notice there is a dropdown selector refresh interval.
It would be great to have this feature! Either as a grid attribute or dropdown with customizable refresh values.
Thanks,
Clement
03:49
Moderators
30/10/2007
Hello,
Look here : http://www.w3schools.com/HTMLD.....terval.asp
And you will have idea how to do that (using ...trigger("reloadGrid").
Best Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Nice. Thanks for the post. Just implemented and this works great.
Here's my code:
var f2Auto = false;
var int;
function enableAutorefresh(state){
f2Auto = state;
if(f2Auto){int=self.setInterval('$("#list").trigger("reloadGrid")',5000)}
else{int=window.clearInterval(int)}
}
</script>
</head>
<body>
<input type="checkbox" id="autorefresh" onclick="enableAutorefresh(this.checked)"> Enable Auto-Refresh
</body>
Most Users Ever Online: 715
Currently Online:
57 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66