string name;
string std_name;
if(name==std_name)
{
//Now here you want to execute your javascript code
}
Learn how to write and execute the javascript code from c# code behind
In my .aspx page I am using a and
protected void submit_Click(object sender, EventArgs e)
{
string popupScript = "";
Page.RegisterStartupScript("Startup", popupScript);
}
Page.RegisterStartupScript is used for registering and executing the client side script. This method takes two parameters. First one is key of type System.String and it acts as a unique key that identifies a script block. Second parameter is script which type is also System.String, it is content of script that will be sent to the client, means it contains your javascript code.
Page.RegisterStartupScript automatically attach the script just before the closing tag of your aspx page object’s
0 comments:
Post a Comment