I'm trying to port my app http://www.wieser-software.com/m/bridge/ from Windows Phone to Win 8, and would like to add keyboard accelerators to the keyboard shown at the bottom of the app.
I have a set of toggle buttons, but can't seem to get anything that hooks the keyboard to the buttons.
I've tried AutomationProperties.AccessKey = "Alt+B" and AutomationProperties.AcceleratorKey="Alt+A" but neither seems to do anything.
What am I missing?
Anthony Wieser | Wieser Software Ltd | www.wieser-software.com
Wednesday, August 22, 2012 8:24 AM
- Moved by Jeff SandersMicrosoft employee, Moderator Wednesday, August 22, 2012 1:39 PM XAML question (From:UI Design for Metro style apps)
This is what you should use:
and you have to write the handler as well!
Jeff Sanders (MSFT)Wednesday, August 22, 2012 1:38 PMModerator
Thanks for the suggestion, but I'm still lost as to what to do here.
In my KeyDown handler, is there a function to call to examine what accelerators are declared on the controls?
And then, as they're attached to toggle buttons, how do I fire the toggle? I tried toggling IsChecked, but the event handlers aren't fired.
Alas, all of the suggestions on the right seem to dump me into WinForms answers, and your link has no sample code. Frustrating.
Anthony Wieser | Wieser Software Ltd | www.wieser-software.comWednesday, August 22, 2012 3:15 PM
This has a complete example at the bottom:
Jeff Sanders (MSFT)
Wednesday, August 22, 2012 4:17 PMModerator
- Proposed as answer by Jeff SandersMicrosoft employee, Moderator Wednesday, August 22, 2012 4:17 PM