title: How do I call a JavaScript function from Asp.Net Code Behind?
body: <p>This is my JavaScript function :</p>
  
  <pre><code>function WantToSave()
  {
      alert('You should save now !');
  }
  </code></pre>
  
  <p>And this is my ASP.NET code behind :</p>
  
  <pre><code>Page.ClientScript.RegisterStartupScript(this.GetType(), "MyKey", "WantToSave();");
  </code></pre>
  
  <p>The <code>RegisterStartupScript</code> function is reached, that's sure. But it won't trigger my JavaScript function. And that second parameter, it is supposed to be a "Key of the starting script" yes but what should I put there?</p>