MVVM binding command to contextmenu item

前端 未结 4 937
执念已碎
执念已碎 2020-12-03 03:45

I\'m trying to bind a command to a menuitem in WPF. I\'m using the same method that\'s been working for all my other command bindings, but I can\'t figure out why it doesn\'

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-03 04:07

    That's a tricky issue, sure marginally you will find a quick workaround, but here is a no-magic-solution:

    It boils down to using the Tag of the PlacementTarget (the Button here).

提交回复
热议问题