Asked By
James Mayer
0 points
N/A
Posted on - 09/13/2012
Hi Experts,
I have received a Fatal Error
Cross-thread operation not valid: Control ‘Splash’ accessed from a thread other than the thread it was created on.
Can I get a remedy of this error?
Do you have any idea about this error message?
Please help me.
I have received a Fatal Error
Hello James,
Note that you cannot be able to access the user interface elements from a thread other than the one that created them. You can go ahead and use Control.Invoke in order to access the user interface elements from other threads.
Also try declaring a DisposeDelegate in MyApplication: Private Delegate Sub DisposeDelegate()
Regards,
Carl
Â
Â
I have received a Fatal Error
Based on my understanding, you want to find some other methods which may work like invoke method, don't you
In my point of view, there is no such methods exist except "invoke".
However, you don't need to call them on each control.
You can use one delegate and some parameters to do that, only "this.Invoke" is needed here.
I have received a Fatal Error
Â
Hello James Mayer,
Unfortunately, one cannot access User elements from the threads other than that which have created them. You can use Control Invoke to access user interface elements from other external threads. This code might also be helpful,
mySplashScreen.Invoke(new MethodInvoker(delegate {
   mySplashScreen.Close();
   mySplashScreen.Dispose();
}));
Â
Hopefully this will be helpful.Good luck with your program.
I have received a Fatal Error
Hi
To resolve this issue side by aforementioned solution also you can apply another technique too. Visit this Techyv post for more information : Fatal error while compiling PowerSDR