This function determines if a window handle is valid.
#define INCL_WINWINDOWMGR /* Or use INCL_WIN, INCL_PM, */ #include <os2.h> HAB hab; /* Anchor-block handle. */ HWND hwnd; /* Window handle. */ BOOL rc; /* Validity indicator. */ rc = WinIsWindow(hab, hwnd);