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>");
}
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>");
}
No comments:
Post a Comment