CodeItBetter Programming Another VB Programming Blog

How to get the type of the Keyboard

Posted on January 5, 2009
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
'System & API - How to get the type of the Keyboard

Option Explicit
 
Private Declare Function GetKeyboardType Lib "user32" (ByVal nTypeFlag As Long) As Long
 
Private Sub Main()
    Select Case GetKeyboardType(0)
    Case 1
        MsgBox "Type of keyboard : " & "PC or compatible 83-key keyboard"
    Case 2
        MsgBox "Type of keyboard : " & "Olivetti 102-key keyboard"
    Case 3
        MsgBox "Type of keyboard : " & "AT or compatible 84-key keyboard"
    Case 4
        MsgBox "Type of keyboard : " & "Enhanced(IBM) 101-102-key keyboard"
    Case 5
        MsgBox "Type of keyboard : " & "Nokia 1050 keyboard"
    Case 6
        MsgBox "Type of keyboard : " & "Nokia 9140 keyboard"
    Case 7
        MsgBox "Type of keyboard : " & "Japanese keyboard"
    End Select
End Sub
Comments (0) Trackbacks (0)

No comments yet.


Leave a comment


 

No trackbacks yet.