title: ASP.net button has to be clicked twice for a jquery function call
body: <p><strong>What I need:</strong> I have the working code that I need to change and update. I have a modal control (Just like a pop up box) that gets called on a button click. Now, I need to calculate something in vb.net code and then make a decision to call it. (pop up box appears) </p>
  
  <p><strong>Problem:</strong> It gets called, but I have to click twice on my button.  The call only happens when the CssClass is set as follows: <code>CssClass="osx ImageButton100"</code></p>
  
  <p><strong>Background:</strong> Modal control that I am using: <a href="http://www.ericmmartin.com/projects/simplemodal-demos/" rel="nofollow">http://www.ericmmartin.com/projects/simplemodal-demos/</a></p>
  
  <p><strong>Changes that were made:</strong></p>
  
  <pre><code>Before:
  
   &lt;asp:Button ID="btnCheckOut" runat="server" Text="Preview Order" CssClass="osx ImageButton100"        /&gt;
  </code></pre>
  
  <p>Now:</p>
  
  <pre><code> &lt;asp:Button ID="btnCheckOut" runat="server" Text="Preview Order"   /&gt;
    btnCheckOut.CssClass = "osx ImageButton100"
  </code></pre>
  
  <p>Complete code:</p>
  
  <p><a href="http://forums.asp.net/post/5367139.aspx" rel="nofollow">http://forums.asp.net/post/5367139.aspx</a></p>