|
Overview |
|
|
|
Group |
|
|
|
Quick Info
Windows NT
| Yes
| Win95
| Yes
| Win32s
| Yes
| Import Library
| user32.lib
| Header File
| winuser.h
| Unicode
| WinNT
| Platform Notes
| None
|
|
|
WinHelp
The WinHelp function starts Windows Help (WINHELP.EXE) and passes additional data
indicating the nature of the help requested by the application. The application
specifies the name and, where required, the directory path of the help file to
display.
BOOL WinHelp(
HWND hWndMain,
| // handle of window requesting Help
| LPCTSTR lpszHelp,
| // address of directory-path string
| UINT uCommand,
| // type of Help
| DWORD dwData
| // additional data
| );
|
|
Parameters
hWndMain
Identifies the window requesting Help. The WinHelp function uses this handle to keep track of which applications have requested
Help.
lpszHelp
Points to a null-terminated string containing the path, if necessary, and the
name of the Help file that the Help application is to display.
The filename may be followed by an angle bracket (>) and the name of a
secondary window if the topic is to be displayed in a secondary window rather than in
the primary window. The name of the secondary window must have been defined in
the [WINDOWS] section of the Help project (.HPJ) file.
uCommand
Specifies the type of help requested. For a list of possible values and how
they affect the value to place in the dwData parameter, see the Remarks section.
dwData
Specifies additional data. The value used depends on the value of the uCommand parameter. For a list of possible values, see the Remarks section.
Return Values
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero.
Remarks
Before closing the window that requested Help, the application must call WinHelp with the uCommand parameter set to HELP_QUIT. Until all applications have done this, Windows
Help will not terminate. Note that calling WinHelp with the HELP_QUIT command is
not necessary if you used the HELP_CONTEXTPOPUP command to start Help
The following table shows the possible values for the uCommand parameter and the corresponding formats of the dwData parameter:
uCommand
| Action
| dwData
| HELP_COMMAND
| Executes a Help macro or macro string.
| Address of a string that specifies the name of the Help macro(s) to execute.
If the string specifies multiple macros names, the names must be separated by
semicolons. You must use the short form of the macro name for some macros because
Help does not support the long name.
| HELP_CONTENTS
| Displays the topic specified by the Contents option in the [OPTIONS] section
of the .HPJ file. This is for backward compatibility. New applications should
provide a .CNT file and use the HELP_FINDER command.
| Ignored, set to 0.
| HELP_CONTEXT
| Displays the topic identified by the specified context identifier defined in
the [MAP] section of the .HPJ file.
| Unsigned long integer containing the context identifier for the topic.
| HELP_CONTEXTPOPUP
| Displays, in a pop-up window, the topic identified by the specified context
identifier defined in the [MAP] section of the .HPJ file.
| Unsigned long integer containing the context identifier for a topic.
| HELP_FORCEFILE
| Ensures that WinHelp is displaying the correct help file. If the incorrect help file is being
displayed, WinHelp opens the correct one; otherwise, there is no action.
| Ignored, set to 0.
| HELP_HELPONHELP
| Displays help on how to use Windows Help, if the WINHELP.HLP file is available.
| Ignored, set to 0.
| HELP_INDEX
| Displays the Index in the Help Topics dialog box. This command is for backward
compatibility. New applications should use the HELP_FINDER command.
| Ignored, set to 0.
| HELP_KEY
| Displays the topic in the keyword table that matches the specified keyword, if
there is an exact match. If there is more than one match, displays the Index
with the topics listed in the Topics Found list box.
| Address of a keyword string.
| HELP_MULTIKEY
| Displays the topic specified by a keyword in an alternative keyword table.
| Address of a MULTIKEYHELP structure that specifies a table footnote character and a keyword.
| HELP_PARTIALKEY
| Displays the topic in the keyword table that matches the specified keyword, if
there is an exact match. If there is more than one match, displays the Index
tab. To display the Index without passing a keyword (the third result), you
should use a pointer to an empty string.
| Address of a keyword string.
| HELP_QUIT
| Informs the Help application that it is no longer needed. If no other
applications have asked for Help, Windows closes the Help application.
| Ignored, set to 0.
| HELP_SETCONTENTS
| Specifies the Contents topic. The Help application displays this topic when
the user clicks the Contents button.
| Unsigned long integer containing the context identifier for the Contents topic.
| HELP_SETINDEX
| Specifies a keyword table to be displayed in the Index of the Help Topics
dialog box.
| Unsigned long integer containing the context identifier for the Index topic.
| HELP_SETWINPOS
| Displays the Help window, if it is minimized or in memory, and sets its size
and position as specified.
| Address of a HELPWININFO structure that specifies the size and position of either a primary or
secondary Help window.
|
See Also
HELPWININFO, MULTIKEYHELP
| Last news from Greatis Software |
 |
|
Nostalgia .Net |
|
.Net is powerful, but not all-powerful, so sometimes we need to use Win32 API for our .Net applications. It's simple enough with Platform Invoke if you have Win32 skill, but we do not always have time to dig the ancient documentation, declare the special types that are compatible with Win32, find the values of the Win32's constants and so on. Nostalgia .Net offers several simple-to-use classes, and components that will allow you to forget about the headache of Win32 and just use the power of Win32 in your application the same way as you use the native. Net classes. More » |
| Recommended software for developers |
 |
|
Ultimate Pack |
|
Component pack for Delphi and C++ Builder that contains runtime form designer, runtime object inspector, print suite and much more for the very special price. More » |
 |
|
Form Designer .Net |
|
Unique runtime form design solution that allows to edit any form in .Net WinForms application at runtime with full source codes for only 300 euro! More » |
 |
|
Print Suite .Net |
|
Print Suite .Net is a set of components for easy printing texts, images and grids from your WinForms applications. Full C# source codes are available More » |
 |
|
Gradient Controls .Net |
|
Gradient Controls .Net offers controls with gradient background feature. Labels, panels and so on... Full C# source codes are available More » |
 |
|
Greatis iGrid |
|
iGrid plots drawing grid right over your desktop, so you can use it everywhere, with any drawing application without any special plugins for different graphic editors. More » |
All the contacts and projectsDmitry Vasiliev (just.dmitry)
Related LinksSoftware for Visual Studio .NET developers Software for Delphi and C++ Builder developers Software for Visual Basic 6 developers Delphi Tips&Tricks MegaDetailed.NET More Online Helps Win32 Programmer's Reference Win32 Multimedia Programmer's Reference OLE Programmer's Reference Microsoft Windows Pen API Programmer's Reference Microsoft Windows Sockets 2 Reference Microsoft Windows Telephony API (TAPI) Programmer's Reference Unix Manual Pages
|