id2 := GlobalAddAtom('Hotkey2');
if RegisterHotKey(Handle, id2, MOD_CONTROL + MOD_Alt ,VK_Delete) then
showmessage('Error, Alt+Ctrl+ Del is already in use. Not registered');
Open in new window
procedure TForm1.Button1Click(Sender: TObject);
i, j : integer;
for i := $41 to $41+25 do
j := GlobalAddAtom('H');
if not RegisterHotKey(Handle, j, MOD_ALT + MOD_CONTROL, i) then
showmessage('Alt + Ctrl + '+ char(i) +' Not available');
showmessage('Alt + Ctrl + '+ char(i) +' Available');
Alt = MOD_ALT
Control = MOD_CONTROL
Shift = MOD_SHIFT
Win button = MOD_WIN
//virtual key codes of the alphabet because it is not clear in the above link from About.com:
A = $41;
B = $42;
C = $43;
D = $44;
E = $45;
F = $46;
G = $47;
H = $48;
I = $49;
J = $4A;
K = $4B;
L = $4C;
M = $4D;
N = $4E;
O = $4F;
P = $50;
Q = $51;
R = $52;
S = $53;
T = $54;
U = $55;
V = $56;
W = $57;
X = $58;
Y = $59;
Z = $5A;
Delete button = $2E; // or use VK_Delete directly
As a web developer or IT admin, successfully managing multiple client accounts can be challenging. In this webinar we will look at the tools provided by Media Temple and Plesk to make managing your clients’ hosting easier.
a, c, s, w, m, h, id: Integer;
ALT: array[0..1] of string = (
'Alt + '
CTRL: array[0..1] of string = (
'Ctrl + '
SHIFT: array[0..1] of string = (
'Shift + '
WIN: array[0..1] of string = (
'Win + '
id := GlobalAddAtom('HotKey');
for a := 0 to 1 do
for c := 0 to 1 do
for s := 0 to 1 do
for w := 0 to 1 do begin
m := a * MOD_ALT +
c * MOD_CONTROL +
s * MOD_SHIFT +
w * MOD_WIN;
desc := ALT[a] + CTRL[c] + SHIFT[s] + WIN[w];
for h := $41 to $5A do begin
if RegisterHotKey(0, id, m, h) then begin
Writeln(desc + Char(h) + ' available');
end else if GetLastError = ERROR_HOTKEY_ALREADY_REGISTERED then
Writeln(desc + Char(h) + ' unavailable')
Writeln('An error occurred!')
on E: Exception do
Writeln(E.ClassName, ': ', E.Message);
Please enter a first name
Please enter a last name
Must be at least 4 characters long.
Join and Comment
From novice to tech pro — start learning today.
Premium members can enroll in this course at no extra cost.
Premium members get this course for $95.20.
Premium members get this course for $62.50.
Premium members get this course for $151.20.
Premium members get this course for $159.20.
Premium members get this course for $299.99.
Premium members get this course for $167.20.
Premium members get this course for $79.20.
Premium members get this course for $143.20.