DevExpress关于对话框

        #region 对话框
        /// 
        /// 确认对话框
        /// 
        /// 提示内容
        /// 用户点击结果
        public DialogResult Confirm(string strString)
        {
            return DevExpress.XtraEditors.XtraMessageBox.Show(strString, "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
        }
        /// 
        /// 确认对话框
        /// 
        /// 提示内容
        public void ShowMessage(string strSting)
        {
            DevExpress.XtraEditors.XtraMessageBox.Show(strSting, "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
        }
        /// 
        /// 确认删除对话框
        /// 
        /// /// 用户点击结果
        public DialogResult ConfirmDelete()
        {
            return DevExpress.XtraEditors.XtraMessageBox.Show("确定要删除吗?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
        }
        #endregion

使用实例:

  if (this.Confirm("确定更新模块程序") == DialogResult.Cancel)
                    return;

 

你可能感兴趣的:(DevExpress关于对话框)