关闭子页面,刷新父页面
父窗口弹出子窗口的 button处理事件:
父窗口html代码添加如下javascript代码:
子窗口关闭窗口的 button处理事件:
private void butDeta_Click(object sender, System.EventArgs e)
{
Response.Write("<script>window.open('CangkuDetaList.aspx?strMateNo="+ txtMateNo.Text +"&strWaretype="+ ddlWareType.SelectedValue +"','new1','width=750,height=400,toolbar=0,scrollbars=2,top=200,left=200');</script>");
}
{
Response.Write("<script>window.open('CangkuDetaList.aspx?strMateNo="+ txtMateNo.Text +"&strWaretype="+ ddlWareType.SelectedValue +"','new1','width=750,height=400,toolbar=0,scrollbars=2,top=200,left=200');</script>");
}
父窗口html代码添加如下javascript代码:
function refresh()
{
this.location = this.location;
}
{
this.location = this.location;
}
子窗口关闭窗口的 button处理事件:
private void imgbtnBack_Click(object sender, System.Web.UI.ImageClickEventArgs e)
{
Response.Write("<script>window.opener.refresh();window.opener=null;window.close();</script>");
}
{
Response.Write("<script>window.opener.refresh();window.opener=null;window.close();</script>");
}