私はこれを使用して にテキストを書き戻しtextbox1
、クロススレッド操作を回避するために正しく機能しますが...そこから1行の出力しか受け取りません。AppendText
基本的なテキスト通話ではなく、より多くの通話を行う方法はありますか?
private void SetText(string text)
{
// InvokeRequired required compares the thread ID of the
// calling thread to the thread ID of the creating thread.
// If these threads are different, it returns true.
if (this.textBox1.InvokeRequired)
{
SetTextCallback d = new SetTextCallback(SetText);
this.Invoke(d, new object[] { text });
}
else
{
this.textBox1.Text = text;
}
}