SetHelp
(Engine-Level Function)
Description: | Sets the help file name and (optionally) the context identifier for the window containing the specified object. |
Returns: | Nothing |
Usage: | Steady State only. |
Function Groups: | Help |
Related to: | Help |
Format: | SetHelp(Object, HelpFileName [, HelpContext]) |
Parameters: |
Object |
Required. The object value of a module instance that is running inside the window whose help context is to be affected. |
HelpFileName |
Required. The file name of the help file to use if the user presses F1 while the specified window is the active window. If Invalid, the parent window of the specified window will be checked for a help file reference. This continues recursively until the top of the window tree is reached. If no help file name is found, the default VTScada help file is used. The default help reference can be set by adding the variable "WEBHelp" to the [System] section of the Setup.INI file, or by using the EnableHelp statement. The help file name may be any .CHM format help file, typically added to the VTScada installation folder. (The .HLP format is obsolete and will not open in modern versions of Windows.) To use the default VTScada Help system, enter simply: \DevHelpFile without quotation marks. |
HelpContext |
Optional help context. If absent or invalid, but the HelpFileName is valid, then the default home page of the help file or system is displayed when the user presses F1. If valid and numeric, the help file is searched for a topic with a matching alias number and help is displayed for that topic. If there is no topic with a matching alias ID value, then NetHelp and MadCapWebHelp formats will open to the default home page. CHM formats will not open. If valid and textual, and if the help file is .CHM format, then the help file is searched for an exact match on the text string in the topic index of the help file. If there is more than one text match, the index is positioned at the first partial string match. NetHelp and MadCapWebHelp formats will ignore a textual value for HelpContext and open to the default home page. If the HelpFileName parameter is invalid, this parameter is ignored. |
Comments: |
The setting of help file name and context for a window performed by this statement overrides those specified by Window statement parameters. When this statement stops, the settings for an affected window revert to the state [if any] set up by the Window statement parameters. If more than one of these statements references the same window, the last one to start wins the race. The object is usually, Self(); if this statement used in the context of a page module. |