asp.net - How to use ClientScript.RegisterClientScriptBlock with Inline code? -


I have an ASPX page where there is no code behind. The server side code is written in the tag with the rotat server attribute.

If I use

  ClientScript.RegisterClientScriptBlock (this.GetType (), "email", "GetEmail ();");   

In the page_load () event, it just print GetEmail (); When page loads

resembles my code

    

Thanks in advance.

Your code-side code as correct & Lt; Script & gt; As the final argument for wrapping in an element:

  Secure Zero Page_load (Object Sender, EventArgse E) {Client script. Registry client (GetType), "email", "GetEmail ();", true); }    

Comments