Multiple UI Threads - Winforms

后端 未结 3 1569
无人及你
无人及你 2020-12-02 01:55

I want to create multiple UI threads in my application. I have simulated the scenario as below. I am creating a new window / form on a button click in a background

3条回答
  •  遥遥无期
    2020-12-02 02:21

    You could handle the MainForm.Closing event and call subForm.Close ( marshalled onto the right thread ) for each sub form.

    I'm not sure why you want the forms on separate threads, though. Can't you just display the sub forms non-modally on the main thread?

提交回复
热议问题