Occurs when a user presses the F1 key and before the help topic is displayed.
Object.OnHelpContext ( pbCancel )
The OnHelpContext event syntax has the following parts:
Name |
Type |
Description |
Object |
A control |
A control object |
pbCancel |
Var Bool |
A boolean expression that specifies whether or not a help topic will be displayed when the user presses the F1 key. |
pbCancel can be one of the following:
Value |
Description |
True |
Does not display a help topic. |
False * |
Displays the user-defined help topic based on the HelpContextID. |
If the object has no HelpContextID, the program will use the HelpContextID of its parent object.
The programmer can override at run time and display a custom help message.
chkAlphaTest.OnHelpContext(pbCancel)
{
if chkAlphaTest.Enabled=FALSE
pbCancel=FALSE
endif
if pbCancel=FALSE
chkAlphaTest.HelpContextID=32
! Set Help topic to 32
endif
}
Applies to all visible controls and the AForm.
Help, HelpContextID, HelpFile, MsgBox, OnWhatsThisHelp, ShowHelpContext, ShowWhatsThis, ToolTipText, WhatsThisButton, WhatsThisHelpID, WhatsThisHelpText, WhatsThisMode