Winform

1 this.Invoke(new Action(() =>
2                         {
3 
4                         }));

Wpf

   this.Dispatcher.Invoke(DispatcherPriority.Normal,
                new Action(() =>
                {
                    //调用主线程UI的的代码  
                    ButtonOkClick(this.msg);
                }));

 

相关文章:

  • 2021-05-23
  • 2022-02-12
  • 2021-12-06
  • 2022-12-23
  • 2021-07-20
  • 2021-08-28
猜你喜欢
  • 2021-09-27
  • 2022-12-23
  • 2021-06-16
  • 2021-08-20
  • 2021-08-19
  • 2021-10-06
相关资源
相似解决方案