public static void OpenPageInNewWindow(Page page, string pageUrl) { Type t=page.GetType(); StringBuilder sb = new StringBuilder(); sb.Append("<script language='javascript'>"); sb.Append("window.open('" + pageUrl + "');"); sb.Append("</script>"); if (!page.ClientScript.IsClientScriptBlockRegistered(t,"newwindow")) { page.ClientScript.RegisterClientScriptBlock(t,"newwindow",sb.ToString()); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)