I have a background worker that is started on the main thread as shown

(source: developingtrends.co.uk)
It executes on a worker thread as expected

(source: developingtrends.co.uk)
but for some reason it completes on the worker thread which causes me issues if I try and update anything on the gui thread.

(source: developingtrends.co.uk)
I have tried a simplified setup on a test app and in this app the thread does end correctly on the main thread

(source: developingtrends.co.uk)
Can you think of any reason this might have happened?
Thanks
Ross
This behavior was seen in older versions of Windows Forms. Even though the BGW is started on the main thread, the value of
SynchronizationContext.Currentwasnull. This bug was fixed sometime in the last year.From my blog: