PatriceVB
Messages postés562Date d'inscriptiondimanche 16 décembre 2001StatutModérateurDernière intervention26 décembre 2007 24 déc. 2002 à 08:46
Il faut utiliser les fonctions api pour faire ça :
Dans un module :
Declare Function GetAsyncKeyState Lib "user32" (ByVal vKey As Long) As Integer
Global Const TOUCHE_F11 = &H7A
Dans un timer :
Dim test As Integer
test = GetAsyncKeyState(TOUCHE_F11)
If test <> 0 Then
msgbox "touche f11 appuyée"
endif
cs_PROGRAMMIX
Messages postés1133Date d'inscriptionmercredi 2 octobre 2002StatutMembreDernière intervention24 juillet 20112 24 déc. 2002 à 09:21
Est-ce qu'on ne peut pas également utiliser la propriété KeyPreview = True pour la feuille et le code Form_KeyPress pour détecter quelle touche a été activée ?