This project has moved and is read-only. For the latest updates, please go here.
new Thread(() => {
var excelWindowThatIsTheOwner = new NativeWindow();

excelWindowThatIsTheOwner.AssignHandle(new IntPtr(Application.Hwnd));

//Show modal dialog (here: a message box, but )
MessageBox.Show(owner: excelWindowThatIsTheOwner,
text: "I am a modal MessageBox.\nNow bring another application to the foreground and then try to bring excel back via the windows taskbar...");

Last edited Jun 9, 2014 at 2:16 PM by govert, version 2