title: Thread doesn't seem to be running in the background
body: <p>I have the following code:</p>
  
  <pre><code>public class BaseControlClass : System.Web.UI.UserControl
  {
      protected delegate void AsyncronousAction();
      protected virtual void FAsyncEvent() { } //Overidden on derived classes.
  
      protected void Page_Load(object sender, EventArgs e)
      {
          if (!Page.IsPostBack)
              FPerformAsyncronousTasks(FAsyncEvent);
      }
  
      protected virtual void FPerformAsyncronousTasks(AsyncronousAction AsyncCallback)
      {
          new Thread(delegate()
          {
              AsyncCallback();
          }).Start();
      }
  }
  
  public class DerivedControlClass : BaseClass
  {
      protected override void FAsyncEvent()
      {
          //Contact web service, wait for results, add to local database.
      }
  }
  </code></pre>
  
  <p>What I was expecting is for the page to load and the code in <code>FAsyncEvent()</code> in my derived class to run behind the scenes however, the page doesn't finish loading until the code in <code>FAsyncEvent()</code> has completed.</p>
  
  <p>Am I doing something wrong with the threading here?</p>
  
  <p><strong>EDIT</strong> Strangely, I have noticed if I do a Clean -> Build then run the code, it works fine and the page finishes loading whilst the web service is being contacted. Subsequent runs though mean the page waits until the thread has finished processing.</p>