摘要: http://www.codeproject.com/Articles/32908/C-Single-Instance-App-With-the-Ability-To-Restore///<summary>///Themainentrypointfortheapplication.///</summary>[STAThread]staticvoidMain(){Application.EnableVisualStyles();Application.SetCompatibleTextRenderingDefault(false);boolonlyInstance=fal 阅读全文
posted @ 2012-07-11 15:45 higirle 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 大家对这个MessageBox 肯定都不陌生,但有谁注意到对话框右上角的x button,什么情况下是enable,什么情况下是disable的?一下为msdn的官方解释:1. http://msdn.microsoft.com/en-us/library/system.windows.messagebox.aspxTo enable a user to close a message box, Show displays a message box that has an OK button and a Close button in the title bar.2. http://sta. 阅读全文
posted @ 2012-07-11 13:26 higirle 阅读(513) 评论(0) 推荐(0) 编辑
摘要: http://msdn.microsoft.com/en-us/library/system.windows.forms.form.formclosing(v=vs.80).aspxprivatevoidConfigurationTool_FormClosing(objectsender,FormClosingEventArgse){if(IsChanged()){DialogResultresult=MessageBox.Show(Resources.ResourceManager.GetString("ConfirmeMessage"),Resources.Resour 阅读全文
posted @ 2012-07-11 10:59 higirle 阅读(290) 评论(0) 推荐(0) 编辑