How to make a messagebox disappear after 3 seconds?

痞子三分冷 提交于 2019-12-10 23:58:47

问题


I have a confirmation screen in my app where I tell the user that his item is saved succesfully. He can press OK and the messagebox will go, but if he does not, how can I make the messagebox disappear after 3 seconds if there is no response?


回答1:


According to MSDN, there is no way to close a messagebox without user action (no method provided for this action) http://msdn.microsoft.com/en-us/library/system.windows.messagebox_methods(v=vs.95).aspx




回答2:


If your message box doesn't need a user action, use Toast Prompt from Coding4Fun toolkit.

http://coding4fun.codeplex.com/



来源:https://stackoverflow.com/questions/9674122/how-to-make-a-messagebox-disappear-after-3-seconds

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!