Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net (http://www.velocityreviews.com/forums/f29-asp-net.html)
-   -   How can I set the browser to refresh automatically without losing viewstate (http://www.velocityreviews.com/forums/t71874-how-can-i-set-the-browser-to-refresh-automatically-without-losing-viewstate.html)

john 01-29-2004 10:11 PM

How can I set the browser to refresh automatically without losing viewstate
 
From my code behind file, I can put a line like this in order to make
the page automatically refresh every minute:

Response.AppendHeader("Refresh", 60);

But the viewstate of the controls is lost when I do this (as opposed
to when the page posts back when I click on a button on the page, in
which case the viewstate is preserved). Is there another way to do an
automatic refresh?

thanks in advance.

Curt_C [MVP] 01-29-2004 10:25 PM

Re: How can I set the browser to refresh automatically without losing viewstate
 
use a javascript client-side time to do a form.submit() over 60 seconds.


--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com


"john" <johngilmer@yahoo.com> wrote in message
news:2947476e.0401291411.225c8053@posting.google.c om...
> From my code behind file, I can put a line like this in order to make
> the page automatically refresh every minute:
>
> Response.AppendHeader("Refresh", 60);
>
> But the viewstate of the controls is lost when I do this (as opposed
> to when the page posts back when I click on a button on the page, in
> which case the viewstate is preserved). Is there another way to do an
> automatic refresh?
>
> thanks in advance.




=?Utf-8?B?SmF5c29u?= 01-29-2004 10:31 PM

RE: How can I set the browser to refresh automatically without losing viewstate
 
what about a META refresh tag

jayson

john 01-30-2004 02:42 PM

Re: How can I set the browser to refresh automatically without losing viewstate
 
Can you please give me an example how to do this? I am new at
javascript. I have tried putting the following function calls in
javascript for my page and they all cause exceptions (with the form
object being undefined or null):

this.submit();
form.submit();
document.form.submit();
document.forms[0].submit();
document.theform.submit();
document.myform.submit();

thanks


"Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message news:<u9B7oZr5DHA.2696@TK2MSFTNGP09.phx.gbl>...
> use a javascript client-side time to do a form.submit() over 60 seconds.
>
>


Curt_C [MVP] 01-30-2004 03:25 PM

Re: How can I set the browser to refresh automatically without losing viewstate
 
I'd suggest a jscript group but.....something like this perhaps

yourFormname is the name in the <FORM...> tag
<SCRIPT LANGUAGE="JavaScript">
setTimeout(yourFormname.submit(),6000);
</SCRIPT>
--
Curt Christianson
Owner/Lead Developer, DF-Software
www.Darkfalz.com


"john" <johngilmer@yahoo.com> wrote in message
news:2947476e.0401300642.3bd5a134@posting.google.c om...
> Can you please give me an example how to do this? I am new at
> javascript. I have tried putting the following function calls in
> javascript for my page and they all cause exceptions (with the form
> object being undefined or null):
>
> this.submit();
> form.submit();
> document.form.submit();
> document.forms[0].submit();
> document.theform.submit();
> document.myform.submit();
>
> thanks
>
>
> "Curt_C [MVP]" <software_AT_darkfalz.com> wrote in message

news:<u9B7oZr5DHA.2696@TK2MSFTNGP09.phx.gbl>...
> > use a javascript client-side time to do a form.submit() over 60 seconds.
> >
> >





All times are GMT. The time now is 09:47 PM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57