views:

204

answers:

1

I have a C# .Net 2.0 app which implements a FullscreenMode like this:

targetForm.WindowState = FormWindowState.Maximized;
targetForm.FormBorderStyle = FormBorderStyle.None;
targetForm.TopMost = true;
WinApi.SetWinFullScreen(targetForm.Handle); // let me know if you need the code of this methode

If the user is in FullscreenMode and tries to open the Help nothing happens(visible to the user), the HelpWindow gets shown up behind my fullscreen form. The helpfile gets openend like this:

string helpPath= Registry.CurrentUser.OpenSubKey(@"Software\...").GetValue("HelpFile") as string;
System.Diagnostics.Process.Start(helpPath); // the helpfile is a *.chm file

Is it possible to start a Process TopMost or bring it in front of the invoking form? And if so, how?

A: 

I've been using the following code to bring the current window to the top:

    [DllImport("user32")]
    static extern int BringWindowToTop(int hwnd);

    BringWindowToTop(this.Handle.ToInt32());
JamesB
I tried that ... it doesn't work
Marcel Benthin