Detecting Caps Lock and other Function Keys in WinForm

Is there a command to detect whether the Caps lock, Num lock, or the Insert key are on in managed COBOL? The command in C# is something like:

 

if (Control.IsKeyLocked(Keys.CapsLock))

    do something

end if.

 

The following command in managed COBOL only detect whether the keys were pressed but does not detect whether the caps lock is on:

 

if e::KeyCode = type Keys::CapsLock

    do something

end-if.

Parents Reply Children