An application can examine the values in the data structure associated with a window by using the WinQueryWindowUShort and WinQueryWindowULong functions. Each of these functions specifies a structure data item to examine. The index value can be an integer representing a zero-based byte index or a constant (QWS_) that identifies a specific item of data. The code fragment in the following figure obtains the programmer-defined identifier of the object window defined in the previous example:

    HWND hwndObject;
    USHORT usObjID;

    usObjID = WinQueryWindowUShort(hwndObject, QWS_ID);


[Back] [Next]