Friday, December 26, 2008

CHM Files

Microsoft Compiled HTML Help is a proprietary format for online help files, developed by Microsoft and first released in 1997 as a successor to the Microsoft WinHelp format. It was first introduced with Windows 98 release.
 
CHM files are a set of HTML files, which are indexed and bound together for easy readability. The files are compressed together with LZX compression.
 
On Windows computers, this help file can be compiled using hcc.exe.
 
To print all topics or a set of topics under a specific sub-topic in a CHM file - right click on a topic or sub-topic and select "Print this heading and all sub-topics".
 
CHM to HTML Conversion
 
A CHM file can be extracted to plain HTML with the command
 
    hh.exe -decompile sample_help sample_help.chm
 
On running the above command all files embedded in sample_help.chm will be extracted to a folder named sample_help.
 
 
How to copy images from a CHM file
 
On copy-pasting images from a CHM file to a word file we will get only an empty rectangle. To properly copy the image we must first paste the image to a image processing application like MS-Paint and then copy that image to Word.
 
Another method is to select "Paste Special" in Word and select the "Device Independent Bitmap" in the dialog that opens up, this will properly paste the image in the Word document.

No comments: