Show Javascript messgae and when click ok then redirect to another page
public static void ShowMsgWithRedirect(System.Web.UI.Page objPage, string msg, string pagename)
{
ScriptManager.RegisterStartupScript(objPage, objPage.GetType(), "", "alert('" + msg + "');window.location ='" + pagename + "';", true);
}
public static void ShowMessage(System.Web.UI.Page objPage, string msg)
{
ScriptManager.RegisterStartupScript(objPage, objPage.GetType(), "", "alert('" + msg + "');", true);
}
public static void ShowConMessage(System.Web.UI.Page objPage, string msg)
{
ScriptManager.RegisterStartupScript(objPage, objPage.GetType(), "", "Confirm('" + msg + "');", true);
}
Comments
Post a Comment