Showing posts with label PopUpWindow. Show all posts
Showing posts with label PopUpWindow. Show all posts

November 1, 2011

Pop Up Window Code in ASP.NET Using JAVA Script

Below is the code to open pop up window is ASP.NET

in .aspx page

 <script type="text/javascript" >
function OpenWindow(url)
{
    newwindow = window.open(url, 'mynewwindow', 'width=500,height=400');  


}
</script>


in .aspx.cs page ( Server Side Code)


protected void OpenNewWindow(object sennder, EventArgs e)
    {
        StringBuilder popupScript = new StringBuilder();
        popupScript.Append("<script language='JavaScript'> window.open('UploadChecks.aspx?OrderSeqNo=" + lblOrderSeqno.Text + "', '', 'width=950, height=580,scrollbars,status,menubar=no,resizable,toolbar=no,titlebar=no,location=no');</script>");
       
    }