Hi Roger,
A nonmodal window i can adjust in the Appwindow exact on pos 0,0 from the parent,
but with a nonmodal there i dont know how to do, that i can it make like in a nonmodal window.
The conflict is, in a nonmodal i can set in DCREADGUI the option ** APWINDOW oParentDlg ** and the window will be positioned on the parent.
With modal the opened window is every time at the appdesktop.
See my attached sample.
Plse help me.
thanks and regards Kurt.
Setpos with a modal window
Setpos with a modal window
- Attachments
-
- modaltest.ZIP
- (1.48 KiB) Downloaded 812 times
Re: Setpos with a modal window
I think this will work for you:
Code: Select all
Function tw2( oDlgtest)
Local GetList := {}, GetOptions, oDlgtw2, oget, cget, oStatic
cget := space(15)
@ .1,.1 DCSTATIC TYPE XBPSTATIC_TYPE_RECESSEDBOX SIZE 50,5.000 OBJECT oStatic
@ 2,05 DCSAY "Test-1 " PARENT oStatic
@ 2,20 DCGET cget OBJECT oget PARENT oStatic
DCGETOPTIONS HIDE
DCREAD GUI FIT ;
MODAL ;
OPTIONS GetOptions ;
SETAPPWINDOW ;
ADDBUTTONS ;
TITLE 'Test-modal' ;
SETFOCUS @oget ;
EVAL {|o,a| a := DC_CalcAbsolutePosition({0,0},oDlgTest), ;
o:setPos({a[1]+5,a[2]+5}), ;
o:show()}
RETURN nil
The eXpress train is coming - and it has more cars.
Re: Setpos with a modal window
Hi Roger,
many thanks for your prompt help.
it works fine
Thanks and regards Kurt
many thanks for your prompt help.
it works fine
Thanks and regards Kurt