private void threadSafeToComBox(string message) { if (this.comBox.InvokeRequired) { threadSafeCallback d = new threadSafeCallback(threadSafeToComBox); this.Invoke(d, new object[] { message }); } else { this.comBox.Text += (message); } }
private void threadSafeToServerCom(string message) { if (this.ServerCom.InvokeRequired) { threadSafeCallback d = new threadSafeCallback(threadSafeToServerCom); this.Invoke(d, new object[] { message }); } else { this.ServerCom.Text += (message); } }