VK_NUMLOCK and it's values

Ok, nice easy one for you VB guru's I am starting into VB and find the best way to lean is to read code as well as books, anyway I came across some code that had the constants as shown below.

I understand that the VK_NUMLOCK = &H90 is equivalent to VK_NUMLOCK = 144 and this is the value associated to the Num Lock key but I am not sure what the  value does within the code, i.e. does it set Num Lock to on?

Const VK_NUMLOCK = &H90

Further into the code is the following line:


I understand that this changes the value but again to what?

It would be great if somebody could give me an explanation of what the other two values are:


and is there a link that gives a full list of the &H1 values and the keys they are associated with.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

The constant will press the NUMLOCK key down,then you have to use KEYUP to release it.For example:

Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Private Const KEYEVENTF_KEYUP = &H2
Const VK_NUMLOCK = &H90

Private Sub Command1_Click()
    keybd_event VK_NUMLOCK, 0, 0, 0 ' Press NUMLOCK key down
    keybd_event VK_NUMLOCK, 0, KEYEVENTF_KEYUP, 0 ' Release it
End Sub
EXTENDED KEY indicates the keystroke you want to send is from an extended key on the keyboard.  Some keys do not have ASCII equivalents, for these the keyboard sends two bytes instead of one for the VK_ code, EXTENDED KEY simulates the 0xE0 (224) prefix that some keys on the keyboard generate.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
trojan_ukAuthor Commented:
Thanks guys
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.