Number lock

Kim Martel kim at
Mon May 24 08:13:19 UTC 2021

Hi Kelly
Thankyou - that was what I was after. It works.

My next thought is there a command that if result=0 that you can
automatically set result to 1


-----Original Message-----
From: omnisdev-en [mailto:omnisdev-en-bounces at] On Behalf
Of Kelly Burgess
Sent: Monday, 24 May 2021 1:10 PM
To: OmnisList <omnisdev-en at>
Subject: Re: Number lock

Hi Kim,

Assuming you're on Windows, try this.  I don't have a keyboard with a
numLock key, but this detects my capsLock key (code 20).  144 is the numLock

   Register DLL ('user32','GetKeyState','JJ') Returns err
   Call DLL ('user32','GetKeyState',144) Returns result
   If result=0
      ; numlock key not pressed
   Else if result=1
      ; numlock key pressed
   End if

Manage your list subscriptions at Start a new
message -> mailto:omnisdev-en at 

This email has been checked for viruses by AVG.

More information about the omnisdev-en mailing list