I've done quite a bit of searching on this and found no real answer.
Is this just a limitation of MessageBoxes?
Just to clarify - I have my main process running as BackgroundWorker and when it is finished, a message box appears to report all finished. Unfortunately it will not be the uppermost window and is often hidden completely behind the program window.
Is there a simple solution to this or do I have to live with it?
Thanks as always in advance.

1 answers
It sounds like your program's form has its Topmost property set to true (the default is false).
If that's the case, then try setting Topmost to false just before calling MessageBox.Show and set it back to true immediately afterwards.
EDIT
OK, in that case, see if the following pattern will work:
SECOND EDIT
Some of the overloads of MessageBox.Show take an IWin32Window object (basically just a window) as the first parameter. This makes the window the MessageBox's owner and, in theory, a window should always appear on top of its owner.
So I'd try something like the following:
If there is still another window on top of the MessageBox, then set your form's Topmost property to true first.
answered one year ago by:
17279
151
Thanks for the feedback. I did check that and the property is set to false.
17279
Please see my edit.
151
Damn. That didn't work either. I'm using a save.dialog just before this step - could that be anything to do with it?
17279
I wouldn't have thought that would make any difference. However, I've had another idea - please see my second edit.
151
Sweet! Second edit cracked it. Many thanks!