How to Create Form from within non gui thread C#

前端 未结 3 1339
礼貌的吻别
礼貌的吻别 2020-12-30 15:08

I have my main GUI from where I start a long running method in a separate thread. Now from within this separate thread I need to create and show a new form. But when I show

3条回答
  •  囚心锁ツ
    2020-12-30 16:13

    Use Form.Show instead of Form.ShowDialog. You can also use a BackgroundWorker to do concurrent tasks.

提交回复
热议问题