Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Shortcut menu relative to command button
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de menu & Menus
Divers
Thread ID:
00867966
Message ID:
00867967
Vues:
26
This message has been marked as the solution to the initial question of the thread.
Hi Phil,

You can temporary switch form scale mode to Foxels to calculate shortcut menu position.
Thisform.ScaleMode = 0		&& Foxels
lnPosX = This.Left + This.Width
lnPosY = This.Top + This.Height
Thisform.ScaleMode = 3          && Back to Pixels
DEFINE POPUP test SHORTCUT RELATIVE FROM (lnPosY), (lnPosX)
DEFINE BAR 1 OF test PROMPT "Menu 1" 
DEFINE BAR 2 OF test PROMPT "Menu 2" 
ACTIVATE POPUP test
>I am struggling trying to get a shortcut menu to be displayed relative to the command button which calls it.
>
>The "print" button is calling the shortcut menu with a simple DO COFC.MPR command.
>
>The shortcut menu works as desired, except it is diplayed at the location of the mouse pointer. I want the top left corner of the menu to be anchored to the bottom right corner of the command button.
>
>Can someone shed some light on this for me??
>
>Thanks.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform