guarda cosa ho trovato nei miei vecchi appunti 
codice:
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = 112 Then
Label1.Caption = Label1.Caption & " F1"
End If
If KeyCode = 113 Then
Label1.Caption = Label1.Caption & " F2"
End If
If KeyCode = 114 Then
Label1.Caption = Label1.Caption & " F3"
End If
If KeyCode = 115 Then
Label1.Caption = Label1.Caption & " F4"
End If
If KeyCode = 116 Then
Label1.Caption = Label1.Caption & " F5"
End If
If KeyCode = 117 Then
Label1.Caption = Label1.Caption & " F6"
End If
If KeyCode = 118 Then
Label1.Caption = Label1.Caption & " F7"
End If
If KeyCode = 119 Then
Label1.Caption = Label1.Caption & " F8"
End If
If KeyCode = 120 Then
Label1.Caption = Label1.Caption & " F9"
End If
If KeyCode = 121 Then
Label1.Caption = Label1.Caption & " F10"
End If
End Sub