Microsoft Help Viewer 1.0 is the format used in VS Help and MSDN for VS version 2010 and higher. After you generate MS Help Viewer (.msh? files) documentation you cannot view it immediately by pressing Show Documentation button on compilation dialog. MS Help Viewer documents must be installed first. After that you can view them in VS help. Unlike e.g. HTML Help with one CHM file, MS Help Viewer documentation usually consists of two files:
When VSdocman generates your MS Help Viewer files, it automatically registers (installs) them on your computer. See Deploying section below. By installing your documentation in MS Help Viewer system we mean:
Note: By default, it is not possible to install MS Help Viewer documentation silently. So a Help Library Manager window will pop-up after generating the help and you must manually confirm the installation. To install help silently on target computer, you must create signed CAB file, see Deploying section below. For more information, read Getting Started with MS Help Viewer. Viewing After you install your documentation, you can see it in VS Help. By default, VS Help opens in your default web browser. You should see your help in Contents, your items will be in Index and you can perform search on your help. However, viewing in browser provides only limited functionality - no full TOC, no Index. So you can use 3rd party viewer:
An F1 help should work as well. Here is a sample of MS Help Viewer topic shown in H3Viewer:
When you recompile your help, it needs to be installed again which may take several minutes. Therefore we recommend you to compile HTML Help 1.x (chm_msdn2) documentation for test purposes and use MS Help Viewer format when you are satisfied with your documentation. |
Installation When deploying your documentation you need to install it on the target computer. This assumes that the following conditions are met:
As already mentioned, VSdocman generates two files - PROJECT_NAME.mshc and helpcontentsetup.msha. Remember that you cannot rename helpcontentsetup.msha, otherwise the installation would fail. The MS Help Viewer runtime contains Help Library Manager (HelpLibManager.exe) which is used for installing and uninstalling the help packages. It works in GUI mode (if invoked for example from VS Help menu) and command line mode. We will use the command line mode. See a full list of command line parameters for HelpLibManager. For the installation use the following syntax: HelpLibManager.exe /product "VS" /version "100" /locale "en-us" /sourceMedia "REAL_PATH\helpcontentsetup.msha" The first three parameters uniquely identify the help catalog which the installed package will belong to. In our case it is VS+100+en-us catalog which is VS 2010 help. The /sourceMedia parameter specifies the path to our manifest file which contains all information necessary for installation. Unfortunately, when installing this way, the HelpLibManager.exe will show in GUI mode. It will automatically add specified help package in the list of packages but you need to manually finish the installation. The following picture shows this dialog for "TestDLL Reference" help package.
You need to click the Add link next to installed package.
Press Update button after that. An alert will appear.
Confirm installation with Yes button. The installation starts to merge indexes. This may take some time. You can exit Help Library Manager when the help is installed. Important: When you attempt to install newer version of already installed package, the installation has no effect. So it's recommended to always uninstall before installation. Uninstalling not installed package doesn't cause any problems. Silent installation As you can see, this approach requires user intervention. However, it is possible to install silently but you need to use signed CAB files. The CAB file is used instead of MSHC file.
Uninstallation For the uninstallation use the following syntax: HelpLibManager.exe /product "VS" /version "100" /locale "en-us" /uninstall /silent Unlike the installation, the uninstallation works in silent mode even when no signed .cab files were used. The first three parameters uniquely identify the help catalog which the package will be uninstalled from. The /vendor, /mediaBookList and /productName were specified in generated helpcontentsetup.msha file during installation. HelpLibManagerLauncher When you install your documentation on target computer, you need to take care of the following:
Therefore we developed small command line tool HelpLibManagerLauncher.exe that does all the job. It simply calls HelpLibManager.exe but before this, it takes care of the abovementioned issues. Registered users of VSdocman can distribute it with their documentation. Files to Deploy As already mentioned, MS Help Viewer documentation consists of several files. You need to distribute all of them to other computers. VSdocman prepares deployment ready directory with all necessary files in output_path/FINAL_HV10_DOC folder:
All you need to do is to copy all those files in one folder on target machine and call register_PROJECT_NAME.bat during installation. Or use commands from this script and call them directly. This is probably preferred method because generated script file doesn't contain correct full path to your .msha file. When user uninstalls your component, you should also uninstall the documentation. Just call unregister_PROJECT_NAME.bat from your uninstaller. |
Distribution Policy
You can distribute your documentation with HelpLibManagerLauncher.exe utility only if you are registered user of VSdocman. You cannot distribute HelpLibManagerLauncher.exe if you are using evaluation (trial) or beta version of VSdocman.
Registered users can distribute HelpLibManagerLauncher.exe royalty-free but only with documentation generated by VSdocman or with documentation which contains parts generated by VSdocman.



