subbu
subbu

Reputation: 3299

Updating DataGrid View in Multithreaded Environment

I have set of c++ dlls and a c# exe . My c++ dlls are multi-threaded and they put data into a Database. My c# exe uses Background worker . My c# exe gets these data to a Data table asynchronously. To achieve this I am using named Mutex. My problem is when I assign this Data Table to my grid view It is crashing. I am using delegates and Begin Invoke .

Upvotes: 0

Views: 311

Answers (1)

Peter
Peter

Reputation: 38555

With begin invoke do you mean myDelegate.BeginInvoke? you could try myForm.Invoke this runs the delegate on the UI Thread...

Upvotes: 1

Related Questions