Dela via


HxMerge.exe

Command-line program that builds combined full-text index (.HxQ) files and combined attribute index (.HxR) files from a set of compiled Help (.HxS) files. You can only build one type of combined index at a time; .HxQ and .HxR files cannot be built simultaneously. These files are based on internal data from the .HxS files, and cannot be edited.

Combining the indexes of two or more .HxS files significantly increases the performance of full-text searches and attribute filtering. Instead of performing a query for each title at run time, a single query can be performed on the combined indexes, increasing efficiency. This is most useful if your Help system consists of two or more .HxS files.

HxMerge is capable of creating combined indexes for any language on a properly configured system (English) running Windows 2000 or later, so long as the appropriate code page information is installed for the target language.

All of the data required to process a job is stored in the HxMerge project file, an XML data file denoted by the .HxM file extension. Because HxMerge.exe reads the project file in well-formed mode, no DTD is required. For more information, see HxMerge Project (.Hxm) File.

Hxmerge [-p[project file]]

Command-line Options

The following table describes the command-line options that are available.

Option

Value

Description

-p

project file

Specifies the project (.HxM) file that contains information about the job to be converted.

Example

These examples use the MergeInclude.txt list file, with the following contents:

c:\test\testtitle.hxs
c:\test\windowtype.hxs
c:\test\frames.hxs

The following example shows how to create a combined full-text index (.HxQ) file:

hxmerge -p fulltext.HxM

The contents of fulltext.HxM:

<?xml version="1.0"?>
<!DOCTYPE HelpAttributes>
<CombinedHelpIndex
Id = "Test"
DTDVersion = "1.0"
FileVersion = "Test"
LangID = "1033"
StopWordFile = "wordlist.txt"
OutputFile = "test.hxq"
BuildResult = "FTS">
<IncludeFile File="MergeInclude.txt"/>
</CombinedHelpIndex>

The following example shows how to create a combined attribute index (.HxR) file:

hxmerge -p attr.HxM

The contents of attr.HxM:

<?xml version="1.0"?>
<!DOCTYPE HelpAttributes>
<CombinedHelpIndex
Id = "Test"
DTDVersion = "1.0"
FileVersion = "Test"
LangID = "1033"
StopWordFile = "wordlist.txt"
OutputFile = "test.hxr"
BuildResult = "Attr" >
<IncludeFile File="MergeInclude.txt"/>
</CombinedHelpIndex>

Remarks

In order for HxMerge to work properly, the user must have File System-level (NTFS) write permissions on the temp folder (the folder referenced by %TEMP% and %TMP%). If the user does not have the correct permissions, an error will result.

For the Microsoft Help runtime to use an .HxQ or .HxR file, it must be registered with the associated HxS file(s). If you are using the HxReg.exe utility, use the -q option to specify the combined full-text index (.HxQ) file and the -t option to specify the combined attribute index (.HxR) file, as follows:

hxreg -n testspace -i devtest -s devtest.hxs -q test.hxq -t test.hxr

Each combined Help (.HxS) file that was built into a combined index should be registered this way in order for it to use the combined index.

If you register a compiled Help (.HxS) file as having a combined index, but the combined index file is missing, Microsoft Help will not revert back to searching the internal index for the .HxS file. Likewise, if the .HxS file is stamped with a different date or version, then the combined index full-text search will be disabled for that .HxS file. If a newer version of an .HxS file is installed on a system, the setup program should re-register that .HxS file to point to a new .HxQ file, or no .HxQ file.

See Also

Concepts

HxMerge Project (.Hxm) File

Reference

HxReg.exe

Other Resources

Getting Started with Help Content and Integration