Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Help file in c#

Options
  • 05-04-2006 10:17am
    #1
    Closed Accounts Posts: 90 ✭✭


    Hi
    I have a help file (help.chm) that I need to add to an application Im working on.
    Anyone know how to do it?

    I see this in the code (I'm only working on it and dont fully understand it)

    But when I go to the Help toolbar item and then click on any of the drop down items (contents, index, search etc) nothing happens.

    Thanks
    Peter


    //
    // _oHelpMenuBarItem
    //
    this._oHelpMenuBarItem.Items.AddRange(new TD.SandBar.ToolbarItemBase[] {
    this.menuButtonItem14,
    this.menuButtonItem15,
    this.menuButtonItem16,
    this.menuButtonItem18,
    this._oAboutVSABMenuButton});
    this._oHelpMenuBarItem.MergeIndex = 6;
    this._oHelpMenuBarItem.Text = "&Help";
    //
    // menuButtonItem14
    //
    this.menuButtonItem14.Icon = ((System.Drawing.Icon)(resources.GetObject("menuButtonItem14.Icon")));
    this.menuButtonItem14.Text = "&Contents";
    //
    // menuButtonItem15
    //
    this.menuButtonItem15.Text = "&Index";
    //
    // menuButtonItem16
    //
    this.menuButtonItem16.Text = "&Search";
    //
    // menuButtonItem18
    //
    this.menuButtonItem18.BeginGroup = true;
    this.menuButtonItem18.Text = "&Report a Bug";


Comments

  • Registered Users Posts: 15,443 ✭✭✭✭bonkey


    Hi
    I have a help file (help.chm) that I need to add to an application Im working on.
    Anyone know how to do it?

    Have you searched/checked MSDN and/or the Visual Studio help? I'm 99% positive that this is covered in reasonable detail there.
    I see this in the code (I'm only working on it and dont fully understand it)

    But when I go to the Help toolbar item and then click on any of the drop down items (contents, index, search etc) nothing happens.
    Well, that makes sense from teh code that you've pasted. This code defines buttons on a menu. Nothing more. That the menu item happens to be have the text "Help", and the sub-items happen to have the text-values "Contents", "Index" and so forth is (effectively) incidental.

    In other words, this code defines a menu. It does not define any event-handlers for what will happen when the various menu items are clicked.

    jc


  • Registered Users Posts: 1,275 ✭✭✭bpmurray


    It's a long time since I played with on-line help, but I can't imagine it's changed much. The MSDN has all the info you need, and there are independent tools to allow you create & use help, many of which are free. See http://www.thefreecountry.com/programming/helpauthoring.shtml for tools & other links.


  • Registered Users Posts: 362 ✭✭theone


    I'm assuming you want this in c#,
    This will work if you place your .chm file on your c drive
    Put the code under the click event of your menu item .

    try
    {
    System.Diagnostics.Process proc = new System.Diagnostics.Process();
    proc.EnableRaisingEvents=false;
    proc.StartInfo.FileName="c://help.CHM";
    proc.Start();
    }
    catch (Exception)
    {
    MessageBox.Show("Theres a problem with the path to your helpFile");
    }


Advertisement