I want a page to refresh automatically every 60 sec. Can some one show me a javascript for that?
Thanks!
I want a page to refresh automatically every 60 sec. Can some one show me a javascript for that?
Thanks!
Or actually invoke service after every 60 sec
Hi Nicklas,
setTimeout(function()
{
Do something here. . .
},
miliseconds of 60sec here. . .
);
Goodluck,
Thanks!
But What do I need to put in to "Do something here"?
Hi Nick,
type the service that you want to execute, for example:
sampleService.execute();
Goodluck,
If you mean refresh is invoking service, such as list service then,
code
var renew = setInterval(function()
{Service.execute({}); }, 60000);
/code
/* Replace 60000 milliseconds(60 secs) to How LONG you want /
/ Replace "Service" to your own service trying to refresh */
http://stackoverflow.com/questions/72...
setTimeout only execute once after a period of time you've set.
Thanks! And where could I Run this script? LoadPage?
Thanks! Works perfect!
how can i refresh the label? For example i would like my web service to run every 5 seconds and then automatically change the label with one of the values.
Hello,
Please use setInterval to run your service each 5 seconds, as Mark said above.:
prevar renew = setInterval(function(){
Service.execute({});
}, 5000);/pre