protected override void OnShown(EventArgs e)
 {
     base.OnShown(e);
     if (MessageBoxDialog.Test_FormShown != null)
     {
         MessageBoxDialog.Test_FormShown(this, EventArgs.Empty);
     }
 }
示例#2
0
        protected virtual DialogResult MessageBox(string message, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
        {
            DialogResult result;

            using (MessageBoxDialog messageBoxDialog = new MessageBoxDialog(message, caption, buttons, icon, UIService.GetDefaultButton(buttons)))
            {
                result = this.ShowDialog(messageBoxDialog);
            }
            return(result);
        }