开发者

Silverlight 3 Window.Closing Event or how to stop a user from closing a browser to stop a running timer

do we have Window.Closing Event in Silverlight version 3? If not, is there an easy way to check if the user is closing the browser and to stop him doing so 开发者_如何学Cunless he explicitly stops a running timer?

Regards, Nadeem.


There is no window closing event in Silverlight directly.

However using the Html bridge you may be able to handle the onbeforeunload event fired by some browsers (IE, Firefox and Safari perhaps more). Even in these cases you only get the option of informing the user about the reason why you don't want them to close and if they agree then they can click the cancel button provided.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜