Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

WPF KeyInputBindings not working

$
0
0

Hi in my view (mainwindow)

i am having keyinputbinding like

<KeyBinding  Key="Left"
                     Command="{Binding Path=FreezeLeftCommand.Command}" />

and in viewmodel i am having code like

public CommandViewModel FreezeLeftCommand
        {
            get
            {
                if (this.freezeLeftCommand == null)
                {
                    freezeLeftCommand = new CommandViewModel(new RelayCommand(Param => this.FreezeLeftRight("Left"), CanFreeze));
                }

                return freezeLeftCommand;
            }
        }

please let me know the solution regarding this

Thanks in advance


Efforts may fail but don't fail to take effort -------------- sidd


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>