Borland Online And The Cobb Group Present:


May, 1995 - Vol. 2 No. 5

Configuring the online help system in BC++ 4.5

If you've ever needed information about Borland C++ 4.0, you've probably used the online help system. However, beginning with version 4.5, Borland has changed the software it uses to display help information (the help engine) when you're using the Integrated Development Environment (IDE). Borland calls the new online help engine OpenHelp.

One of the biggest advantages to the new help system is that you can customize its scope and content. For example, you may want to see only those help topics that relate to the ObjectWindows Library. In this article, we'll show how you can speci-fy what information the help system will search through and display when you use Borland C++ 4.5's online help.

Opening OpenHelp

Most of the time, you won't notice that Borland has changed the help engine that the IDE uses, since the context-sensitive help rules will display the correct help information immediately. However, if you ever use the help system's Search All command to locate a subject in the help files, you'll see a search dialog box, shown in Figure A, that you haven't seen before.


Figure A - The new help engine displays a dramatically different search dialog box.

When trying to find a given topic to display help for, OpenHelp searches an index of help files that belong to a given set, also known as a range. By default, all the help files that ship with version 4.5 belong to a range named, appropriately, BC 4.5.

Therefore, if you try to choose another range from the In This Range combo box, you'll find that BC 4.5 is the only range available. If you want to search a different set of help files (either a subset of the standard help files or help files from another product), you can add new ranges to the OpenHelp system by using the OpenHelp Configuration utility you'll find in the Borland C++ 4.5 program group.

From the OpenHelp Configuration utility, you can modify or delete the existing BC 4.5 range, or you can add and customize new ranges of your own. Once you've specified the new ranges for OpenHelp, the OpenHelp Configuration utility will create a new index file for OpenHelp to use when it searches for a given topic.

Rearranging help files

To see how easily you can customize OpenHelp, let's work through an example of creating a new range that contains the help information for the ObjectWindows Library only. To begin, double-click on the OpenHelp Configuration icon.

When the Configure OpenHelp dialog box appears, you'll see the list of current search ranges in the list box on the left and a list of available help files in the list box on the right, as shown in Figure B. Click Create

Figure B - The OpenHelp Configuration utility allows you to modify the organization of the help files the OpenHelp system uses.

Range.

In the dialog box that appears, enter OWL 2.5 and click OK. When the dialog box disappears, you'll see the new range in the Search Ranges list box.

Next, select the OWL 2.5 range by clicking on it with the left mouse button. Then, select the ObjectWindows Library help file

C:\BC45\BIN\OWL.HLP

that appears in the Help Files list box.

As soon as you select the OWL.HLP help file, you'll notice that the << button that's between the two list boxes is now available. Click << to add this help file to the OWL 2.5 range.

When the new help file becomes part of the current range, you'll see the file's name appear in a hierarchical display beneath the range name, as shown in Figure C. Click OK to generate the index file for OpenHelp.

Figure C - When you add a help file to a range, it appears as a subnode of that range.

When the OpenHelp Configuration utility finishes generating the index file, it automatically closes and returns you to Program Manager. To try out the new help range, double-click on OpenHelp to run the help system without launching the IDE.

When the OpenHelp dialog box appears, enter string in the Search For entry field. Then, choose OWL 2.5 from the In This Range combo box, choose SubString from the Using This Method combo box, and click Search. In a moment, you'll see all of the help topics from the ObjectWindows help file that contain the substring string, as shown in Figure D. Click Close to exit the OpenHelp system.


Figure D - If you create your own help ranges, you can restrict which help topics the help system will display.

Conclusion

The OpenHelp online help system brings a new level of customization to Borland C++ 4.5. By defining your own help ranges, you can adjust the scope of a specific keyword search when you use the Search All com-mand in the help system.

Return to the Borland C++ Developer's Journal index

Subscribe to the Borland C++ Developer's Journal


Copyright (c) 1996 The Cobb Group, a division of Ziff-Davis Publishing Company. All rights reserved. Reproduction in whole or in part in any form or medium without express written permission of Ziff-Davis Publishing Company is prohibited. The Cobb Group and The Cobb Group logo are trademarks of Ziff-Davis Publishing Company.