You can call CHM Help API via command line or DLL function.
· Command line of HTML Help Viewer (HH.EXE)
You can call it via command line or ShellExecute of WinAPI.
Example: HH.EXE ms-its:Helpfile.chm::/Topic.htm HH.EXE mk:@MSITStore:Helpfile.chm::/Topic.htm Use Mapid: HH.EXE –mapid 1000 ms-its:Helpfile.chm |
The prefix mk:@MSITStore is an earlier version of the ms-its protocol that works with Microsoft Internet Explorer 3.0 or later.
-mapid Opens the requested .chm in the Help viewer, and uses a context ID to request a URL to display.
· HTML Help API (HtmlHelp function in HHCtrl.ocx)
You can call the function via DLL mode.
HWND HtmlHelp( HWND hwndCaller, LPCSTR pszFile, UINT uCommand, DWORD dwData) ; Example: HWND hwnd = HtmlHelp(
GetDesktopWindow(),
"c:\\Helpfile.chm::/Topic.htm ",
HH_DISPLAY_TOPIC, NULL) ; Use mapid: HWND hwnd = HtmlHelp(
GetDesktopWindow(),
"c:\\Helpfile.chm",
HH_HELP_CONTEXT, 1000) ; |
More details please refer to About the HTML Help API Function and About Commands.
Related Topics