This project has moved. 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...");
}).Start();

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