Click here to Skip to main content
15,909,896 members
Home / Discussions / WPF
   

WPF

 
GeneralRe: Is IEnumerable a sufficent type for WPF binding? Pin
Abhinav S12-Jan-12 18:00
Abhinav S12-Jan-12 18:00 
GeneralRe: Is IEnumerable a sufficent type for WPF binding? Pin
Dean Oliver23-Jan-12 19:08
Dean Oliver23-Jan-12 19:08 
QuestionTooltip on DataGridTemplateColumn header [solved] Pin
Ravi Bhavnani11-Jan-12 6:01
professionalRavi Bhavnani11-Jan-12 6:01 
AnswerRe: Tooltip on DataGridTemplateColumn header Pin
Ravi Bhavnani11-Jan-12 6:10
professionalRavi Bhavnani11-Jan-12 6:10 
QuestionRIA Service not generating custom property Pin
Icarus12310-Jan-12 18:24
Icarus12310-Jan-12 18:24 
QuestionWPF Model From Hyperlink Pin
Kevin Marois10-Jan-12 10:50
professionalKevin Marois10-Jan-12 10:50 
GeneralRe: WPF Model From Hyperlink Pin
SledgeHammer0110-Jan-12 17:53
SledgeHammer0110-Jan-12 17:53 
GeneralRe: WPF Model From Hyperlink Pin
SledgeHammer0111-Jan-12 6:30
SledgeHammer0111-Jan-12 6:30 
Oh, my bad, I misread the OPs post. I originally read it as he was trying to click on the TreeViewItem node. He is not, so there is a much simpler way. My EventToCommand answer still stands as the "proper" way to forward control events to the VM, but that is not needed in this case.

For the sake of argument, here is how you would use the EventToCommand class:

<i:Interaction.Triggers>
<i:EventTrigger EventName="ItemKeyDown">
<wfx:EventToCommand Command="{Binding ElementName=stateCountyCtrl, Path=DataContext.KeyDownCommand}" PassEventArgsToCommand="True" />
</i:EventTrigger>
</i:Interaction.Triggers>

You would put that in whatever object owned the event.

Then your RelayCommand<T> (the KeyDownCommand here) would take whatever EventArgs type the event is raising.

See my other response to the OP for the "correct" answer in this case.
AnswerRe: WPF Model From Hyperlink Pin
SledgeHammer0111-Jan-12 6:34
SledgeHammer0111-Jan-12 6:34 
QuestionWPF TabControl Events Pin
Tom Delany10-Jan-12 5:03
Tom Delany10-Jan-12 5:03 
GeneralRe: WPF TabControl Events Pin
Pete O'Hanlon10-Jan-12 9:57
mvePete O'Hanlon10-Jan-12 9:57 
GeneralRe: WPF TabControl Events Pin
Tom Delany10-Jan-12 10:15
Tom Delany10-Jan-12 10:15 
GeneralRe: WPF TabControl Events Pin
Pete O'Hanlon10-Jan-12 10:29
mvePete O'Hanlon10-Jan-12 10:29 
GeneralRe: WPF TabControl Events Pin
Tom Delany10-Jan-12 10:35
Tom Delany10-Jan-12 10:35 
GeneralRe: WPF TabControl Events Pin
Tom Delany10-Jan-12 10:17
Tom Delany10-Jan-12 10:17 
GeneralRe: WPF TabControl Events Pin
Pete O'Hanlon10-Jan-12 10:32
mvePete O'Hanlon10-Jan-12 10:32 
GeneralRe: WPF TabControl Events Pin
Tom Delany10-Jan-12 10:37
Tom Delany10-Jan-12 10:37 
GeneralRe: WPF TabControl Events Pin
Pete O'Hanlon10-Jan-12 10:38
mvePete O'Hanlon10-Jan-12 10:38 
GeneralRe: WPF TabControl Events [Edited] Pin
Tom Delany10-Jan-12 11:34
Tom Delany10-Jan-12 11:34 
GeneralRe: WPF TabControl Events [Edited] Pin
Mycroft Holmes10-Jan-12 13:11
professionalMycroft Holmes10-Jan-12 13:11 
GeneralRe: WPF TabControl Events Pin
Tom Delany10-Jan-12 14:08
Tom Delany10-Jan-12 14:08 
GeneralRe: WPF TabControl Events Pin
Tom Delany11-Jan-12 3:40
Tom Delany11-Jan-12 3:40 
GeneralRe: WPF TabControl Events Pin
Tom Delany12-Jan-12 7:53
Tom Delany12-Jan-12 7:53 
GeneralRe: WPF TabControl Events [Edited] Pin
Tom Delany11-Jan-12 8:32
Tom Delany11-Jan-12 8:32 
GeneralRe: WPF TabControl Events [Edited] Pin
Pete O'Hanlon11-Jan-12 8:46
mvePete O'Hanlon11-Jan-12 8:46 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.