SPECIAL OFFER        Order and save right now!
20% off with the 729824315 dicscount code for Ultimate Pack and any another product for Delphi from Greatis Programming!

⤷ Get info about keyboard

Use GetKeyboardType function. Parameter 0 of this function will allow to get keyboard type and parameter 2 will allow to get number of functional keys of your keyboard.

procedure TForm1.Button1Click(Sender: TObject);
  Str: string;
  case GetKeyboardType(0) of
    1: 	Str:='IBM PC/XT or compatible (83-key) keyboard';
    2:	Str:='Olivetti "ICO" (102-key) keyboard';
    3:	Str:='IBM PC/AT (84-key) or similar keyboard';
    4:  Str:='IBM enhanced (101- or 102-key) keyboard';
    5:  Str:='Nokia 1050 and similar keyboards';
    6:  Str:='Nokia 9140 and similar keyboards';
    7:	Str:='Japanese keyboard';
  Label1.Caption:='Keyboard type is '+Str;

  case GetKeyboardType(2) of
    1,3,5: Str:='10';
    2,4: Str:='12';
    6: Str:='24';
    7: Str:='Hardware dependent and specified by the OEM';
    else Str:='N/A';
  Label2.Caption:='Number of functional keys is '+Str;
More for developers
Databases for Amazon Associates
Amazon Categories
Amazon Nodes