Exemple #1
0
 /// <summary>
 /// 询问提示提示
 /// </summary>
 /// <param name="txtMessage"></param>
 /// <param name="txtTitle"></param>
 /// <returns></returns>
 public static DialogResult ShowBoxIf(string txtMessage)
 {
     newMessageBox                 = new YKMessageBox();
     newMessageBox.Text            = "删除确认";
     newMessageBox.lblMessage.Text = txtMessage;
     return(newMessageBox.ShowDialog());
 }
Exemple #2
0
 /// <summary>
 /// 提示内容及标题
 /// </summary>
 /// <param name="txtMessage"></param>
 /// <param name="txtTitle"></param>
 /// <returns></returns>
 public static void  ShowBox(string txtMessage, string txtTitle)
 {
     newMessageBox                   = new YKMessageBox();
     newMessageBox.Text              = txtTitle;
     newMessageBox.lblMessage.Text   = txtMessage;
     newMessageBox.btnCancel.Visible = false;
     newMessageBox.ShowDialog();
 }
Exemple #3
0
 /// <summary>
 /// 提示异常内容
 /// </summary>
 /// <param name="txtMessage"></param>
 /// <returns></returns>
 public static void ShowBoxException(string txtMessage, Exception ex)
 {
     _ex                             = ex;
     newMessageBox                   = new YKMessageBox();
     newMessageBox.Text              = "异常错误";
     newMessageBox.lblMessage.Text   = txtMessage;
     newMessageBox.btnCancel.Visible = false;
     newMessageBox.btnSent.Visible   = true;
     newMessageBox.ShowDialog();
 }
Exemple #4
0
 /// <summary>
 /// 删除提示
 /// </summary>
 /// <param name="txtMessage"></param>
 /// <param name="txtTitle"></param>
 /// <returns></returns>
 public static DialogResult ShowBoxDel(string txtMessage)
 {
     newMessageBox      = new YKMessageBox();
     newMessageBox.Text = "删除确认";
     if (string.IsNullOrEmpty(txtMessage))
     {
         txtMessage = "确认要删除本条记录吗?";
     }
     newMessageBox.lblMessage.Text = txtMessage;
     return(newMessageBox.ShowDialog());
 }