Question

In my main form I have this code:

        FormHelpLauncher formHelpLauncher = new FormHelpLauncher();
        formHelpLauncher.LaunchHelpFile(chmFilename);

The FormHelpLauncher code looks like this:

   public partial class FormHelpLauncher : Form
   {
      public FormHelpLauncher()
      {
         InitializeComponent();
      }


      public void LaunchHelpFile(string chmFilename)
      {
         System.Windows.Forms.Help.ShowHelp(this, chmFilename, HelpNavigator.TableOfContents);
      }
   }

This instantiates (but does not display) a Forms class, and then launches a CHM help file. The idea behind using the not-displayed auxiliary Forms class is that it provides extra decoupling between the help window and my program's main window. In particular, it results in the help window being included in the Alt-Tab list, which is what I prefer.

Now my question: Is there any way I can specify the icon that will be shown by Alt-Tab for the help window? I've tried various things, but Alt-Tab is always displaying the white-sheet-of-paper-with-yellow-question-mark icon.

Was it helpful?
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top