private void addCommand(string text)
 {
     if (this.tbxStatus.InvokeRequired)
     {
         addCommandCallback d = new addCommandCallback(addCommand);
         this.Invoke(d, new object[] { text });
     }
     else
     {
         this.tbxStatus.Text += text + Environment.NewLine;
     }
 }
示例#2
0
 private void addCommand(string text)
 {
     try
     {
         if (this.tbxStatus.InvokeRequired)
         {
             addCommandCallback d = new addCommandCallback(addCommand);
             this.Invoke(d, new object[] { text });
         }
         else
         {
             this.tbxStatus.Text += text + Environment.NewLine;
         }
     }
     catch (Exception e)
     {
         addCommand("# Error set text tbxStatus \n\n" + e);
     }
 }