GX5296, GX5961, GX5964
Opens a virtual panel window used for interactively controlling the domain boards.
GtDio6xPanel (pnHandle, hwndParent, nMode, phwndPanel, pnStatus)
Name |
Type |
Comments |
pnHandle |
PSHORT |
Session identifier:● Board handle is used when communicating with the hardware. The Board handle session identifier is returned by calling GtDio6xInitialize or GtDio6xSetupInitialization. |
hwndParent |
HWND |
Panel parent window handle. A value of 0 sets the desktop as the parent window. |
nMode |
SHORT |
The mode in which the panel main window is created, two modes:0. GTDIO6X_PANEL_MODELESS: for modeless window. 1. GTDIO6X_PANEL_MODAL: for modal window. |
phwndPanel |
HWND |
Returned window handle for the panel. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
The function is used to create the panel window. The panel window may be open as a modal or a modeless window depending on the nMode parameters.
If the mode is set to modal dialog (nMode=1), the panel will disable the parent window (hwndParent) and the function will return only after the window was closed by the user. In that case, the pnHandle may return the handle created by the user using the panel Initialize dialog. This handle may be used when calling other GTDIO6X functions.
If a modeless dialog was created (nMode=0), the function returns immediately after creating the panel window returning the window handle to the panel phwndPanel. It is the responsibility of calling program to dispatch windows messages to this window so that the window can respond to messages.
The following example calls the Panel:
HWND hwndParent, hwndPanel;
SHORT nStatus;
GtDio6xPanel (hwndParent, GTDIO6X_PANEL_MODELESS, &hwndPanel,
nStatus);