How can I find the state of NumLock, CapsLock and ScrollLock keys in .NET?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Import the WinAPI function GetKeyState:
And then you can use it like this:
It is for framework 1.1. For framework 2.0 (and later) you can use:
Control.IsKeyLocked