I have a backgroundworker which calls a method in the
DoWork event.
this method accesses a dataset in the UI Thread and it also calls a another method in the UI Thread.
my problem comes in when the method requires access to datasets and methods that exists in the Ui Thread, I get a cross thread operation not valid error.
How can I access Items UI Thread?
Is it possible for me to access it using the backgroundworker or must I use another method of running my method in a background thread
Thanks
You just need to marshal the method call to the UI thread.
On WinForms: