title: how to call javascript function in Web user Control ascx
body: <p>I have the following Code on test.ascx <strong>ASP Control</strong>:</p>
  
  <pre><code>  function mute() {       
          var button_mute = document.getElementById('&lt;%= btnRequestCompanyCheck.ClientID %&gt;');
          button_mute.style.display = "none";
          alert("x");
  
      }
  </code></pre>
  
  <p>How I can call mute() from Code behind (test.ascx.cs), I am trying all of below list, no one is working for me.
  Which one should I used on <strong>Asp.net Control</strong>?</p>
  
  <pre><code>ScriptManager.RegisterOnSubmitStatement(this, this.GetType(), "test", "mute()");
  ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "test", "mute()", true);
  ScriptManager.RegisterStartupScript(this, this.GetType(), "test", "mute()", true);
  ScriptManager.RegisterStartupScript(this, this.GetType(), "test", "mute()", true);
  Page.ClientScript.RegisterStartupScript(this.GetType(), "CallMyFunction","mute()", true);
  </code></pre>