Hello,
How can I read the position and the size of a dilalog box in my application?
Thx.
How to read position and size of a dialog box (solved)
How to read position and size of a dialog box (solved)
Last edited by driessen on Sun Oct 20, 2019 7:06 pm, edited 1 time in total.
Regards,
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Re: How to read position and size of a dialog box
Michel ,
:nTop
:nLeft
:nBottom
:nRight
regards
Uwe
:nTop
:nLeft
:nBottom
:nRight
regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.
- Marc Venken
- Posts: 727
- Joined: Tue Jun 14, 2016 7:51 am
Re: How to read position and size of a dialog box
From a post of Uwe :
aRect := GetWndRect(oWnd)
oBar := TExplorerBar():New( 0, aRect4 - 300, aRect4 + 720, aRect3 - 75, oWnd )
Mayby also on oDlg
aRect := GetWndRect(oWnd)
oBar := TExplorerBar():New( 0, aRect4 - 300, aRect4 + 720, aRect3 - 75, oWnd )
Mayby also on oDlg
Marc Venken
Using: FWH 20.08 with Harbour
Using: FWH 20.08 with Harbour
Re: How to read position and size of a dialog box
To get the dialog position from screen-top and left and the dialogsizeHow can I read the position and the size of a dilalog box in my application?
oRect := oDlg:GetRect()
nTop := oRect:nTop
nLeft := oRect:nLeft
nWidth := oDlg:nWidth
nHeight := oDlg:nHeight
// ----------------
Resizing a dialog You need as well :
nBottom := oRect:nBottom
nRight := oRect:nRight
// restore the dialog to a saved position
oDlg:Move( nTop, nLeft, nRight - nLeft, nBottom - nTop )
Window :
aRect := GetWndRect( oWnd:hWnd )
nTop := aRect[ 1 ]
nLeft := aRect[ 2 ]
nBottom := aRect[ 3 ]
nRight := aRect[ 4 ]
nHeight := aRect[ 3 ] - aRect[ 1 ] + 1
nWidth := aRect[ 4 ] - aRect[ 2 ] + 1
regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.
Re: How to read position and size of a dialog box
Hello everybody,
Thank you all very much for your help.
Testing will start tomorrow.
Thank you all very much for your help.
Testing will start tomorrow.
Regards,
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Re: How to read position and size of a dialog box
Hello, everyone.
I did some tests and everything is working just fine.
Thank you all so much for your help.
I did some tests and everything is working just fine.
Thank you all so much for your help.
Regards,
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7
Michel D.
Genk (Belgium)
_____________________________________________________________________________________________
I use : FiveWin for (x)Harbour v. 21.01 - Harbour 3.2.0 (October 2020) - xHarbour Builder (January 2020) - Bcc7