Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
F2 Key!
Message
De
04/01/2006 10:55:42
 
 
À
Tous
Information générale
Forum:
Visual Basic
Catégorie:
Autre
Titre:
F2 Key!
Divers
Thread ID:
01083152
Message ID:
01083152
Vues:
63
Hello

I'm having a hard time coding the F2 key to trigger a specific action on a form.

I tried this sample code I got form the net and it just won't work;

Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyF2 Then
MsgBox "You Pressed F2!"
End If
End Sub

If I change vbKeyF2 for vbEnter, it works fine. What's wrong with my F2 key?

Thanks!
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform