|hi guys , im using the zeromq dll , and most of you knows , that this dll is handling the socket programming job .
okay , after that im define a dealer , i used the dealer.recived event is like
dealer.OnReceived += delegate(byte bytes, bool multipart)
string recive = Encoding.UTF8.GetString(bytes);
message = recive.Split('|');
if (Application.OpenForms["form2"] != null)
Cross-thread operation not valid: Control 'Form2' accessed from a thread other than the thread it was created on.
this error belong to the application.openform.
i know one thing , when im using the threading opreation , i should define a new delegate to just invoke the object and get access of it , but here i dont really know what should i do to just close the form2.
so , any idea , i'll appriciate that .