示例#1
0
文件: Form1.cs 项目: daytch/AutoClick
 private void ValidationID2(object sender, CancelEventArgs e)
 {
     if (string.IsNullOrWhiteSpace(ID2Input.Text))
     {
         e.Cancel = true;
         WebTargetInput.Focus();
         errorMsgID2.SetError(ID2Input, "Parameter should not be left blank!");
     }
     else
     {
         e.Cancel = false;
         errorMsgID2.SetError(ID2Input, "");
     }
 }
示例#2
0
文件: Form1.cs 项目: daytch/AutoClick
 private void ValidationLooping(object sender, CancelEventArgs e)
 {
     if (string.IsNullOrWhiteSpace(LoopingInput.Text))
     {
         e.Cancel = true;
         WebTargetInput.Focus();
         errorLooping.SetError(LoopingInput, "Looping should not be left blank!");
     }
     else
     {
         e.Cancel = false;
         errorLooping.SetError(LoopingInput, "");
     }
 }
示例#3
0
文件: Form1.cs 项目: daytch/AutoClick
 private void ValidationWebTargetInput(object sender, CancelEventArgs e)
 {
     if (string.IsNullOrWhiteSpace(WebTargetInput.Text))
     {
         e.Cancel = true;
         WebTargetInput.Focus();
         errorProvider1.SetError(WebTargetInput, "Web target should not be left blank!");
     }
     else
     {
         e.Cancel = false;
         errorProvider1.SetError(WebTargetInput, "");
     }
 }