Call javascript function from code behind in C#
Suppose you want to call javascript function ParentRefresh() from code behind in C#.
<script type="text/javascript">
function ParentRefresh()
{
// javascript code
}
</script>
protected void Save_Click(object sender, EventArgs e)
{
// your save code
ScriptManager.RegisterStartupScript(this, GetType(), "message", "ParentRefresh();", true);
}
No comments:
Post a Comment