那么有什么办法可以在浏览器中禁用“刷新”按钮?或者至少处理F5?
解决方法 这里有几个选项http://forums.silverlight.net/forums/p/105879/243232.aspx
来自链接:
One option is to hook into the window
object ‘onbeforeunload’ event and
prompt the user to confirm the
refresh/exit intent. Here is a
simple example that Could be defined
in your HTML markup or even emitted
from the SL app (if it has DOM
access):
<script type="text/JavaScript">window.onbeforeunload = function() { return "Leaving or refreshing this page can result in data loss.";}</script>总结
以上是内存溢出为你收集整理的Silverlight:如何禁用浏览器的刷新按钮?全部内容,希望文章能够帮你解决Silverlight:如何禁用浏览器的刷新按钮?所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)