Based on this tutorial, it looks like you want something like:
Response.AddHeader("REFRESH", "30;URL=test.aspx");
Assuming test.aspx
is the target and you want the redirection to occur after thirty seconds.
Question
I am wanting to have a rotating pages in my application and I have found how to redirect to another page. My question is how can incorporate a certain time frame of when to redirect. example to clarify:
if (!IsPostBack)
{
Response.AppendHeader("PageSwitch", (ConfigurationManager.AppSettings["PageSwitch"]));
Response.Redirect("test.aspx", true);
}
I was trying to have the page switch off a value I set in my AppSettings in web config that way it can be changed. I have this as a start. I can't turn the AppendHeader into an if statement because of void to bool problems. How can I make this to load the new page after 30 seconds or preferably after my value in AppSettings?
Solution
Based on this tutorial, it looks like you want something like:
Response.AddHeader("REFRESH", "30;URL=test.aspx");
Assuming test.aspx
is the target and you want the redirection to occur after thirty seconds.