winform 方式:
public delegate void MyInvoke(string str1);
private void check_Click(object sender, RoutedEventArgs e)
{
//跨现场调度1 delete委托 WIMFORM
Task.Run(() =>
{
MyInvoke mi = new MyInvoke(UpdateFormTEXT);
mi.Invoke("数据");// mi.BeginInvoke("数据",null,null);
});
wpf方式:
//跨现场调度1 delete委托 WPF
this.Dispatcher.Invoke(() => {
this.findWhatTextBox.Text = "SHUJU";
});
}