Retrieves the GuiControl object of a GUI control associated with the specified window handle.
GuiControlObj := GuiCtrlFromHwnd(Hwnd)
Type: Integer
The window handle (HWND) of a GUI control, or a child window of such a control (e.g. the Edit control of a ComboBox). The control must have been created by the current script via Gui.Add.
Type: Object or String (empty)
This function returns the GuiControl object associated with the specified HWND, or an empty string if there isn't one or the HWND is invalid.
For example, a HWND of a GUI control can be retrieved via GuiControl.Hwnd, MouseGetPos or OnMessage.
Gui(), Gui object, GuiControl object, GuiFromHwnd, Control Types, ListView, TreeView, Menu object, Control functions, MsgBox, FileSelect, DirSelect
See the ToolTip example on the Gui object page.