I have a class that receives data from serialport. i used action<T> delegate
to pass data to the form where it is displayed in a textbox. the thing is i could not access the textbox
control, becouse it says: Cross-thread operation not valid: Control accessed from a thread other than the thread it was created on
.
so i set Control.CheckForIllegalCrossThreadCalls = false
, and it is working.
is it good idea to do that? or there is a better way of doing it.
Thanks