Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Open the Windows start menu programatically?
Message
De
12/11/2004 09:59:06
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00960509
Message ID:
00960835
Vues:
8
Hi Pete,

The code below tries to emulate the Ctrl+Esc keyboard shortcut for the Start menu. You can not do it with KEYBOARD unfortunately. Hope your ankle improves soon. Mine took about 4 weeks.
#DEFINE KEYEVENTF_KEYUP 0x002	&& Flag indicating key was released
#DEFINE VK_CONTROL      0x011	&& Virtual key code
#DEFINE VK_ESCAPE       0x01B
#DEFINE MSCAN_CONTROL   0x09D	&& Make scan code
#DEFINE MSCAN_ESCAPE    0x081
#DEFINE BSCAN_CONTROL   0x09D	&& Break scan code
#DEFINE BSCAN_ESCAPE    0x081

DECLARE INTEGER keybd_event IN Win32API INTEGER, INTEGER, INTEGER, INTEGER


=keybd_event(VK_CONTROL,MSCAN_CONTROL,0,0)               && Press   CONTROL
=keybd_event(VK_ESCAPE ,MSCAN_ESCAPE ,0,0)               && Press   ESCAPE
=keybd_event(VK_ESCAPE ,BSCAN_ESCAPE ,KEYEVENTF_KEYUP,0) && Release ESCAPE
=keybd_event(VK_CONTROL,BSCAN_CONTROL,KEYEVENTF_KEYUP,0) && Release CONTROL
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform