Returns or changes the text of a window or control
_Win$(hWnd)=x$
x$ = _Win$(hWnd)
hWnd:window handle
x$:svar
Corresponds somewhat to TitleW, but instead of a window number you must specify a window handle (e.g. Win(1) or Win_1.hWnd). In contrast to TitleW, you can also change the title/contents of Controls (e.g. EditText).
OpenW # 1
Dim x$ = _Win$(Win_1.hWnd)
If x$ != "Win #1"
_Win$(Win(1)) = "Win #1"
Print _Win$(Win(1))
EndIf
Do
Sleep
Loop Until Me Is Nothing
The OCX forms and controls have a property to set the text or caption. _Win$() is a shortcut for the APIs SetWindowText and GetWindowText.
{Created by Sjouke Hamstra; Last updated: 23/09/2014 by James Gaite}