Embedding an HTML Help window into a dialog. | CodeGuru

Embedding an HTML Help window into a dialog.

CHHCtrl is an MFC class designed for placing an embedded help window inside of a dialog, property sheet, or window. The CHHCtrl class hosts shdocvw directly rather then using the HtmlHelp API. This bypasses the bugs in embedded help introduced with the version of HTML Help released with Visual Studio 6. It also gives you […]

Written By
CodeGuru Staff
CodeGuru Staff
Nov 11, 1998
1 minute read
CodeGuru content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More

CHHCtrl is an MFC class designed for placing an embedded help window inside of a dialog, property sheet, or window.
The CHHCtrl class hosts shdocvw directly rather then using the HtmlHelp API. This bypasses the
bugs in embedded help introduced with the version of HTML Help released with Visual Studio 6.
It also gives you access to all IWebBrowser methods which means you can change HTML files on the
fly — for example, showing the actual key associations currently in effect for
a program rather then the default set it ships with.

This project also includes a CItsFile class that you can use for reading any file from a CHM (or ITS) file. It is used by
the CHHCtrl class for convertting mapped ids into URLs, but you can use it to read any kind of data that is stored in
the CHM file.

Because of additions to MFC that CHHCtrl relies on, this project requires Visual Studio 6. You may be
able to port it to an earlier version of Visual Studio, but expect a fair amount of work.

The zip file includes additional information (chhctrl.htm) covering how to add CHHCtrl into your project, and
documents other functionality that CHHCtrl provides.

Download demo project – 48 KB

CodeGuru Logo

CodeGuru covers topics related to Microsoft-related software development, mobile development, database management, and web application programming. In addition to tutorials and how-tos that teach programmers how to code in Microsoft-related languages and frameworks like C# and .Net, we also publish articles on software development tools, the latest in developer news, and advice for project managers. Cloud services such as Microsoft Azure and database options including SQL Server and MSSQL are also frequently covered.

Property of TechnologyAdvice. © 2026 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.