title: Disable a button when clicked then enable after refresh
body: <p>I have a button on a page that when clicked runs a sub that populates a gridview with data from an SQL table.  I am using VS2010 with VB.</p>
  
  <p>When a user clicks the submit button I want to disable it instantly and then run the sub and once the sub has ran enable the button again.</p>
  
  <p>I added the below to the button click event but it does not work</p>
  
  <pre><code>        imgbtnComDetailGo.enabled = False
  
      Call Sub()
      imgbtnComDetailGo.enabled = True
  </code></pre>
  
  <p>It does not appear to be disabling the button instantly.</p>
  
  <p>UPDATE - I found this code on google </p>
  
  <pre><code>OnClientClick="this.disabled = true" UseSubmitBehavior="true"
  </code></pre>
  
  <p>but it does not appear to call the SUB as nothing happens apart from the button gets disabled.</p>