Figer's Technology Consulting | Launch a new window in ASP.NET on a button click using Javascript

Launch a new window in ASP.NET on a button click using Javascript

The code is pretty simple, but it's nice to have this snippet around when you need it. 

 Dim ReportURL as string = "http://www.figers.com" 
 Dim js As String = "<script language=""javascript"" type=""text/javascript""> 

window.open('" & ReportURL & "');</script>" Page.ClientScript.RegisterClientScriptBlock(Me.GetType, "NewWindow", js)
Comments are closed