阅读背景:

从ItemTemplate中绑定到ItemsControl的DataContext

来源:互联网 

I have an ItemsControl whose for the ItemTemplate DataTemplate contains a Button. I want the Command on the button to bind to a Command on the DataContext of the ItemsControl, not the ItemTemplate. I think the solution has to do with using RelativeSource, but my attempts so far have failed:I have an ItemsControl whose for the ItemTempla




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: