1)
protected void BtnCanc_Click(object sender, EventArgs e)
{
try
{
StringBuilder sb = new StringBuilder();
sb.Append("<script>");
sb.Append("window.close('')");
sb.Append("</script>");
this.Page.ClientScript.RegisterStartupScript(this.GetType(), "PopupScript", "SP.UI.ModalDialog.commonModalDialogClose(0, 0);", true);
}
finally
{
}
}
2)
<form>
<input type="button" value="Close Window" visible="false" onClick="window.close()">
</form>
<a href="javascript:window.close()">Close Window</a>
protected void BtnCanc_Click(object sender, EventArgs e)
{
try
{
StringBuilder sb = new StringBuilder();
sb.Append("<script>");
sb.Append("window.close('')");
sb.Append("</script>");
this.Page.ClientScript.RegisterStartupScript(this.GetType(), "PopupScript", "SP.UI.ModalDialog.commonModalDialogClose(0, 0);", true);
}
finally
{
}
}
2)
<form>
<input type="button" value="Close Window" visible="false" onClick="window.close()">
</form>
<a href="javascript:window.close()">Close Window</a>
No comments:
Post a Comment