Unload 事件请参见
全部显示
当服务器控件从内存中卸载时发生。[Visual Basic]
Public Event Unload As EventHandler[C#]
public event EventHandler Unload;
[JScript] 在 JScript 中,可以处理由某个类定义的事件,但不能定义自己的事件。事件数据
事件处理程序接收一个 EventArgs 类型的参数。
全部显示
当服务器控件从内存中卸载时发生。[Visual Basic]
Public Event Unload As EventHandler[C#]
public event EventHandler Unload;
[JScript] 在 JScript 中,可以处理由某个类定义的事件,但不能定义自己的事件。事件数据
事件处理程序接收一个 EventArgs 类型的参数。
win=window.showModalDialog(YouPage.aspx?Parameter='+OneParameter,window,'status=no;center=yes;help=no;dialogWidth=110px;dialogHeight=220px;scroll=no;resize=no');
if(win=='t')
{
//do some thing
}
新页面关闭时:
Response.Write("<script language=javascript>window.returnValue='t';</script>");
Response.Write("<script language=javascript>window.close();</script>");这样你就能在新页面关闭时对主页面做一些事情了。
2、谈开一个新窗口的花,如果客户端安装了3721等的花就彻底完了,
谈不出窗口来
function window.onbeforeunload()
{
if(event.clientX>document.body.clientWidth&&event.clientY<0||event.altKey)
{
window.event.returnValue="确定要退出本页吗?";
}else
{
alert("你在刷新");
}
}
</script>
这样可以通过ie的差退出是可以,但是通过菜单不能捕捉