cwbCO_SetWindowHandle

Purpose

This function sets, for the specified system object, the window handle to use if any prompting is to be done that is associated with the system object (for example, prompting for user ID and password). When so set (to a non-NULL window handle), such a prompt would appear 'modal' to the main application window and therefore never would get hidden behind that window.

Syntax

 
UINT CWB_ENTRY cwbCO_SetWindowHandle(
                             cwbCO_SysHandle     system,
                             HWND                windowHandle );

Parameters

cwbCO_SysHandle system - input
Handle that previously was returned from cwbCO_CreateSystem or cwbCO_CreateSystemLike. It identifies the iSeries™ system.
HWND windowHandle - input
Specifies the window handle to associate with the system object. If NULL, no window handle is associated with the system object.

Return Codes

The following list shows common return values:

CWB_OK
Successful completion.
CWB_INVALID_API_HANDLE
Invalid system handle.

Usage

This API may be used any time to change the window handle for the specified system object, even after a successful signon.