HTML Help URLs

Many of the HTML Help commands require that you specify a HTML Help URL in the pszFile parameter of the HtmlHelp function. This URL is used to specify a helpfile, sometimes including a specific topic within a helpfile and often a window type in which to display the topic. An HTML Help URL has the following format

Compiled help (.chm) file [::/Topic] [>WindowType]

The commands reference in this helpfile uses this same format to document the requirements for the pszFile parameter of the HtmlHelp() function. Note that text between square brackets is optional. The Compiled (.chm) file is used to specifiy the helpfile, optionally including the full path to the helpfile. The Topic is used to specify a topic within the helpfile and WindowType is used to specify the window. If you include a topic then the helpfile and topic must be separated by ::/ For example

JediHtmlHelp.chm::/Introduction.htm

Specifies the JediHtmlHelp.chm as the compiled help (.chm) file and Introduction.htm as the topic. Often you will use a folder structure to maintain your help topics. For instance this helpfile has a root folder called HTML. Within this folder are separate folders which hold all topic files for a specific major section. An example would be the HTML\Api Reference folder. This same folder structure is maintained in the compiled help (.chm) file unless this option has been turned off. To refer to a topic you'll need to specify the entire path to that topic. For example, to refer to the Api Reference.htm topic in the HTML\Api Reference folder you would write

JediHtmlHelp.chm::/HTML\Api Reference\Api Reference.htm

Note that the HTML Help compiler automatically replaces spaces in the path with %20. Also, you can use both forward or backward slashes to separate the folders in the path although the forward slash is the one that is documented and hence should be the one you use. The separation between the helpfile and the topic must use a backward slash though. So the following would be identical

JediHtmlHelp.chm::/HTML/Api Reference/Api Reference.htm

When you include a window type in the URL the window type must be separated with the rest of the URL by using a greater then character (>). For example, to specify the Main window type you would use

JediHtmlHelp.chm::/HTML\Api Reference\Api Reference.htm>Main

or if the topic is not specified

JediHtmlHelp.chm>Main

Notes:
You can display a topic from an HTML Help file in your browser by using the ms-its plugable protocol. For example, to display the "About The Author" topic in Internet Explorer 4.0 or higher you can use:

ms-its:D:\Project JEDI\Conversions\HTML Help\Help\JediHtmlHelp.chm::/HTML\About the author.htm