I have the following Code on test.ascx ASP Control:
function mute() {
var button_mute = document.getElementById('<%= btnRequestCompanyCheck.ClientID %>');
button_mute.style.display = "none";
alert("x");
}
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 Asp.net Control?
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);