You should use the Invoke method in the form, for example. with an anonymous delegate to make changes to the reaction to the event.
An event handler is created using another thread. This 2nd thread cannot access the controls in your form. It must βcallβ them so that the thread does all the management work that originally created them.
Instead:
myForm.Control1.Text = "newText";
you need to write:
myForm.Invoke(new Action( delegate() { myForm.Control1.Text = "newText"; }));
Mischa
source share