locked
Enhancement Request: Detect CapsLock, NumLock, ScrollLock state RRS feed

  • Question

  • I think this is a bug, but ok, I post this as an Enhancement Request.


    Add support for natively checking the status (pressed or not) for this three keys.

    Regards,

    Pablo Roca

    Friday, March 11, 2011 1:05 PM

Answers

  • Hi Daoping,

    I didn't knew that forum existed, thanks for pointing it out.

    The ER is already there as:

    http://dotnet.uservoice.com/forums/4325-silverlight-feature-suggestions/suggestions/660425-add-access-to-keyboard-device-and-or-capslock-stat?ref=title

    Wednesday, March 16, 2011 5:24 AM

All replies

  • I'm not sure a Mac has a ScrollLock key...

    Saturday, March 12, 2011 8:36 PM
  • As far as I know there is not ScrollLock Key in Mac, I think it can be done with Shift F1. Anyway, my problem is mainly with CapsLock.

    The better would be that Silverlight could differencciate a 'A' key from an 'a' key in the KeyDown event, so then it wouldn't be necessary to check the CapsLock.

    Monday, March 14, 2011 4:37 AM
  • Posted also in Microsoft Connect, please vote for it, thanks.

    https://connect.microsoft.com/VisualStudio/feedback/details/651261/silverligh-detect-keystrokes-in-lower-uppercase-in-keydown-event

    Monday, March 14, 2011 5:49 AM
  • You can try Key.CapsLock, not tested (but easy to test!)

    You can however find out if Capslock or some other special keys are on by making use of KeyEventArgs.PlatformKeyCode that's actually send at onKeyDown.You can look up the Virtual Key-code for capslock in here: http://msdn.microsoft.com/en-us/library/ms927178.aspx

    At this moment it's not possible to detect whether CapsLock is on or off without making use of one of the Key Events.

    Monday, March 14, 2011 2:43 PM
  • Thanks for your reply Odahan,

    Yes, Key.CapsLock fires in the KeyDown event. But the problem is to detect if this key is on or off before running your SilverLight app or when another control has the Focus.

    The better would be that the Key.? could detect uppercase & lowercase

    Tuesday, March 15, 2011 4:35 AM
  • Hi,

    detect if this key is on or off before

    I have to tell you that current vesion Silverlight does not support this feature

    But how to detect if CapsLock key is on or off which can be a feature request.

    You can submit your suggestion on Silverlight Feature Suggestions Forum.

    After you submit your suggestion, you can also provide the link you open from Silverlight Feature Suggestions Forum on here so that other members can know your suggestion and can vote it.

     

    Regards

    Wednesday, March 16, 2011 4:31 AM
  • Hi Daoping,

    I didn't knew that forum existed, thanks for pointing it out.

    The ER is already there as:

    http://dotnet.uservoice.com/forums/4325-silverlight-feature-suggestions/suggestions/660425-add-access-to-keyboard-device-and-or-capslock-stat?ref=title

    Wednesday, March 16, 2011 5:24 AM