How to invoke a server-side function with JavaScript


Firstly, you can drag a server button and put the server function into the button Click even, 
protected void Button1_Click(object sender, EventArgs e)
{
   FunctionName();
}

Secondly, you can call the server function at JavaScript by using the following code,
document.getElementById("Button1").click();