Will Response.Redirect() stop a thread?

  • Thread starter Thread starter Mark Huebner
  • Start date Start date
M

Mark Huebner

I have an aspx web page with the following C# code in the page load event.
Can somebody tell me if the Response.Redirect() will cause my tLoadDNN
thread to stop executing before it is finished? tLoadDNN might occasionally
take up to 16 seconds to complete.

protected void Page_Load(object sender, EventArgs e)
{
Thread tLoadDNN = new Thread(new ThreadStart(LoadDNN));
tLoadDNN.Start();
Response.Redirect("Default1.htm");
}
 
If the second parameter is "false", does that mean the Response.Redirect
won't redirect to the new URL until the thread finishes executing? I would
like it to redirect immediately to the new URL while the thread continues to
execute.
 
If the second parameter is "false", does that mean the Response.Redirect
won't redirect to the new URL until the thread finishes executing?
Yes.

I would like it to redirect immediately to the new URL

Response.Redirect("somepage.aspx", false);
return;
 
Back
Top