Triggering button command on key down
We have a few buttons in our application like
Is there a way to make a button trigger its command (MenuCommand) on key down rather than key up?
Code: Select all
<Button x:Name="MenuButton" Content="Menu" Command="{Binding MenuCommand}" />
-
sfernandez
Site Admin
- Posts: 3005
- Joined:
Re: Triggering button command on key down
Yes, you just need to change Button's ClickMode="Press".
Commands are executed after Button generates the Click event.
Commands are executed after Button generates the Click event.
Who is online
Users browsing this forum: Ahrefs [Bot], Bing [Bot], Semrush [Bot] and 4 guests