Using the Help API
Specify the left, top, width and height variables in the respective properties of the UDT.
Note that WinHelp divides the screen up into units so that both the width and height are 1024 units. The wStructSize should be set so that the API knows how long the structure is. The state contains the desired window state; it is similar to the shell command's windowstyle parameter. The options are:
SW_HIDE | Hides the window and passes activation to another window. |
SW_MINIMIZE | Minimises the specified window and activates the top level window in the Z order. |
SW_RESTORE | Same as SW_SHOWNORMAL. |
SW_SHOW | Activates a window and displays it in its current size and position. |
SW_SHOWMAXIMIZED | Activates the window and displays it as a maximised window. |
SW_SHOWMINIMIZED | Activates the window and displays it as an icon. |
SW_SHOWMINNOACTIVE | Displays the window as an icon. The window that is currently active remains active. |
SW_SHOWNA | Displays the window in its current state. The window that is currently active remains active. |
SW_SHOWNOACTIVATE | Displays a window in its most recent size and position. The window that is currently active remains active. |
SW_SHOWNORMAL | Activates and displays the window. Whether the window is minimised or maximised, Windows restores it to its original size and position. |
rgchMember does not do anything, so should be left empty.
Page 4 of 5
This article was originally published on November 20, 2002