c# - Calling a new Form from a separate thread and avoid frozing the form -


I'm currently creating a chat system The receiving end of the client side is managed by a separate thread so that when it's any Once the message is received from other clients, a new form is filled with the sender's message. The problem is that the newly loaded form is stable and [I'm not using it due to blocked methods (?)] How can I solve that problem? If I'm new to C #, please insert the code snippet.

This is frozen because you created it another thread and that thread did not apply. The need to 'pump the message loop'.

Do not make windows on the second thread. Use background worker or control. Basic Invoc or Dispatcher Start to create a window for your program's UI threads.

Comments