Archive

Posts Tagged ‘close aspx page’

Closing Aspx page on PostBack by suppressing close confirmation

February 4, 2012 Leave a comment

Hi,

Below is the code to close the current .aspx page in the Postback (i.e., On Button click) without “Close” confirmation dialog

// Close the window with no close confirmation

Response.Write(“<script language=’javascript’> { window.open(”, ‘_self’, ”); window.close(); }</script>”);

Hope it helps 🙂

Advertisement