예제 #1
0
파일: FrmMain.cs 프로젝트: vla/HashFile
 private void answer_Completed(object sender, AsyncFuncCompletedEventArgs <MessageInfo> e)
 {
     if (!e.Cancelled)
     {
         if (e.Error == null)
         {
             BarTime.Value          = 100;
             TxtView.Text           = e.Result.ToString();
             TxtView.SelectionStart = TxtView.TextLength;
             TxtView.ScrollToCaret();
             e.Result.AppendLine(Environment.NewLine);
         }
         else
         {
             MessageBox.Show(e.Error.Message, "Info");
             BarTime.Value  = 0;
             BarCount.Value = 0;
         }
     }
     else
     {
         BarCount.Value = 0;
         BarTime.Value  = 0;
     }
     CmdStop.Enabled = false;
 }
예제 #2
0
파일: FrmMain.cs 프로젝트: vla/HashFile
 private void answer_Completed(object sender, AsyncFuncCompletedEventArgs<MessageInfo> e)
 {
     if (!e.Cancelled) {
         if (e.Error == null) {
             BarTime.Value = 100;
             TxtView.Text = e.Result.ToString();
             TxtView.SelectionStart = TxtView.TextLength;
             TxtView.ScrollToCaret();
             e.Result.AppendLine(Environment.NewLine);
         } else {
             MessageBox.Show(e.Error.Message, "Info");
             BarTime.Value = 0;
             BarCount.Value = 0;
         }
     } else {
         BarCount.Value = 0;
         BarTime.Value = 0;
     }
     CmdStop.Enabled = false;
 }