예제 #1
0
 /// <summary>
 /// 显示指定的消息
 /// </summary>
 /// <param name="text"></param>
 /// <param name="title"></param>
 public void showMessage(string text, string title = "提示")
 {
     mUCChorme.UICall(() =>
     {
         MSMessageBox.ShowModal(MSMessageBox.MSMessageBoxButton.OK, title, text);
     });
 }
예제 #2
0
 /// <summary>
 /// 显示警告对话框
 /// </summary>
 /// <param name="window"></param>
 /// <param name="text"></param>
 /// <returns></returns>
 public static MSMessageBox.MessageResult ShowMessageExclamation(this ContentControl window, string text)
 {
     return(MSMessageBox.ShowModal(MSMessageBox.MSMessageBoxButton.OK, "警告", text));
 }
예제 #3
0
 /// <summary>
 /// 显示错误信息对话框
 /// </summary>
 /// <param name="window"></param>
 /// <param name="ex">错误</param>
 /// <returns></returns>
 public static MSMessageBox.MessageResult ShowMessageError(this ContentControl window, Exception ex)
 {
     return(MSMessageBox.ShowModal(MSMessageBox.MSMessageBoxButton.OK, "错误", Helpers.ExceptionHelper.GetMessage(ex)));
 }