This project has moved and is read-only. For the latest updates, please go here.


Feb 28, 2011 at 7:13 PM


is it possible  to add a KeyBinding to a DelegateCommand?

I try to add a KeyBinding to the InputBindings collection of a UserControl in XAML but it's not invoked, only if I add it to the main ShellWindow.



Mar 1, 2011 at 7:31 PM

Hi Tyia,

Yes this works. Please have a look at the Writer sample application: “Writer.Presentation / Views / MainView.xaml”. This is a UserControl which is hosted inside the ShellWindow.

    <KeyBinding Command="{Binding NewCommand}" Key="N" Modifiers="Control"/>


Mar 4, 2011 at 10:43 AM
Edited Mar 4, 2011 at 10:50 AM

I don't seem to get it to work, it never fires if is attached to any UI element other than the main window.

Also my name is not Tyia, TYIA means "Thank You In Advance" ;)


Edit: I think I found the answer: