I want to define the position and size of a Word-window out of my application.
I use these functions :
1. To find which is the Word-window :
- Code: Select all Expand view
FUNCTION FindWnd(cTitle)
LOCAL hWnd := GETWINDOW(GETDESKTOPWINDOW(),GW_CHILD)
WHILE hWnd <> 0
IF UPPER(cTitle) $ UPPER(GETWINDOWTEXT(hWnd))
RETURN(hWnd)
ENDIF
hWnd := GETWINDOW(hWnd,GW_HWNDNEXT)
ENDDO
RETURN(NIL)
2. To define the position and the size of the Word-window :
- Code: Select all Expand view
LOCAL cWnd := FindWnd("WORD")
IF !EMPTY(cWnd)
BringWindowToTop(cWnd)
cWnd:Top := US->WORDTOP
cWnd:Left := US->WORDLEF
cWnd:Width := US->WORDWID
cWnd:Height := US->WORDHEI
ENDIF
Unfortunately I got an error "No exporterd method : top".
How can I establish the positioning of a Word-window ?
Thanks a lot for any help.