RAD Studio
ContentsIndex
PreviousUpNext
How VCL Controls Process Help

All VCL controls that derive from TControl expose several properties that are used by the Help system: HelpType, HelpContext, and HelpKeyword

The HelpType property contains an instance of an enumerated type that determines if the control's designer expects help to be provided via keyword-based Help or context-based Help. If the HelpType is set to htKeyword, then the Help system expects the control to use keyword-based Help, and the Help system only looks at the contents of the HelpKeyword property. Conversely, if the HelpType is set to htContext, the Help system expects the control to use context-based Help and only looks at the contents of the HelpContext property. 

In addition to the properties, controls expose a single method, InvokeHelp, that can be called to pass a request to the Help system. It takes no parameters and calls the methods in the global Application object, which correspond to the type of Help the control supports. 

Help messages are automatically invoked when F1 is pressed because the KeyDown method of TWinControl calls InvokeHelp.

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!