Olaf,
Nope nope nope.
I have tried this on the same form, with lots of re-sizes with MAIN.SCX as the control where all other forms "live". I have sized it differently and tested on different monitors and many resolutions.
HOWEVER, it's based on the calling control. Where I consider the full size of the form, then where the form inside main is, then where the control is, then add a specific off-set based on that control. It works perfect every time. The code for that is here:
Code:
DO FORM VFACILITYNAV.SCX WITH BINTOC(FACILITY.COMPANYID), ALLTRIM(This.Name), This.Left+ThisForm.Left+This.Width, This.Top+ThisForm.Top+This.Parent.Parent.Top TO lnGetFacility
This is that magic pop-up form that you helped me with in getting the mouse move to position the record pointer, and then single-click.
Within the VFACILITYNAV.SCX the init is:
Code:
LPARAMETERS lnCompanyID, lcTestCity, lnLeftWindow, lnTopWindow
*
This.Left = lnLeftWindow+20
This.Top = lnTopWindow+50
Which provides an addition based on the control size where the MouseEnter occurred in the first code block.
Then we only care about the relative position of the current window to the current control, and an offset.
I think, I'm starting to get good at this again.
Best Regards,
Scott
MIET, MASHRAE, CDCP, CDCS, CDCE, CTDC, CTIA, ATS
"Everything should be made as simple as possible, and no simpler."
![[hammer] [hammer] [hammer]](/data/assets/smilies/hammer.gif)