Returns or sets the context id number for invoking help for the object.
Object.HelpContextID [ = lVal ]
The HelpContextID property syntax has the following parts:
Name |
Type |
Description |
Object |
Object |
An object |
lVal |
Long |
An integer specifying the context id number for invoking help for the object. |
lVal can be one of the following:
Value |
Description |
0 * |
No context number specified. |
> 0 |
An integer specifying a valid context number. |
For context-sensitive Help on an object in the application, the same context number must be assigned to both object and to the associated Help topic when the Help file is compiled.
When a user presses the F1 key, the program automatically calls Help and searches for the topic identified by the current context number.
The current context number is the value of HelpContextID for the object that has the focus. If HelpContextID is set to 0, then the program looks in the HelpContextID of the object's container, and then that object's container, and so on. If a nonzero current context number can't be found, the F1 key is ignored.
The following statement changes the ASwitch HelpContextID to point to item number 55 in the help file:
sw1.HelpContextID=55
All controls and the following classes:
Help, HelpFile, MsgBox, OnHelpContext, OnWhatsThisHelp, ShowWhatsThis, ToolTipText, WhatsThisButton, WhatsThisHelpID, WhatsThisHelpText, WhatsThisMode