Page 1 of 1
drag visualization
Posted: Wed Dec 17, 2008 1:27 pm
by Silvio
Antonio,
on a form whe n I take an control I want show on cursor the control and then I move the mouse on row,col and when I release the button of the mouse it draw the control on row,col ( of the mouse) .
Howe I can make it ?
Posted: Fri Dec 19, 2008 2:31 pm
by Antonio Linares
Silvio,
Please review fwh\samples\TestDrp3.prg
You can change a control position doing:
oControl:nTop := ...
oControl:nLeft := ...
Re: drag visualization
Posted: Tue Aug 11, 2009 3:24 pm
by ukoenig
Antonio,
to make it easier, to place Logos or Vtitles on a defined Position inside a Dialog,
is it possible, to get the Screen-Position ( Top / Left ) for a given ID-Number of a Control from Resources ?
Sample :
I want to place with ABpaint a Logo above a Get-Field with ID 100 ( Position Top = 100, Left = 20 )
The Top / Left Calculation of the Logo would be :
Top = Get-Top - Space - Logo-Height
Left = Get Left
It would make it much easier, to place something on Screen in Relation to a Control.
Thank You
Best Regards
Uwe
Re: drag visualization
Posted: Fri Aug 14, 2009 4:45 pm
by James Bott
Uwe,
Try:
Code: Select all
nID := 100
for i:= 1 to len( oDlg:aControls )
if oDlg:aControls[i]:nID == nID
nTop:= oDlg:aControls[i]
nLeft:= oDlg:aControls[i]
endif
endif
James