1、定义委托 1 delegate void SetTextCallback(string text); 2、实现委托 1 2 3 4 5 6 7 8 9 10 11 12 13 private void SetText(string text) { //如果调用控件的线程和创建创建控件的线程不是同一个则为True if (this.textBox1.InvokeRequired) { SetTextCallback d = new SetTextCallback(SetText); this.textBox1.Invoke(d, new object[] { text }); } else { this.textBox1.Text = text; } } 3、线程中调用该方法 1 2 3 4 5 6 private void ThreadProc() { //do something this.SetText("123"); }