Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Avoid overlapping objects or SYS(1270)
As documented, SYS(1270, nX, nY) returns a reference to the object at location(nX, nY), if any. In other words, I'm trying to use SYS(1270) to identify and reference objects in forms.
The problem is that nX and nY are absolute coordinates; neither relative to the form nor to the main VFP window. So, in order to avoid overlapping objects or even referencing objects at certain locations one has to translate the position within the form that contains the object to absolute coordinates, which can be done using SYSMETRIC() to calculate dimensions of form's title and frame. The catch is that the form must be defined in desktop (form.desktop = .T.).
My question is how could one translate local coordinates in forms contained in the VFP window (form.desktop = .F.) to global coordinates.
NOTE: consider also that some toolbars may also be active and docked at the top or leftmargin of the screen, which affect (or not affect, rather) the form's Left and Top properties.
TIA
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement