WINDOW attribute

A handle to the window that owns a widget or that contains the owner of a widget.

Data type: HANDLE

Access: Read-only

Applies to: BROWSE widget, BUTTON widget, COMBO-BOX widget, CONTROL-FRAME widget, DIALOG-BOX widget, EDITOR widget, FIELD-GROUP widget, FILL-IN widget, FRAME widget, IMAGE widget, LITERAL widget, MENU widget, MENU-ITEM widget, RADIO-SET widget, RECTANGLE widget, SELECTION-LIST widget, SLIDER widget, SUB-MENU widget, TEXT widget, TOGGLE-BOX widget, WINDOW widget

For a menu bar or pop-up menu of a window, the WINDOW and OWNER attributes have the same value. For a window, the WINDOW attribute returns the window's handle (not its parent's handle, if any). For a menu bar or pop-up menu of a window, the WINDOW and OWNER attributes have the same value.