6
に結合WPFまあ、私はそれが簡単に私のシナリオは2つの要素を持っているだと思うは要素
<ListBox Name="BannedItemsListBox"
Margin="5"
MinWidth="100"
MaxWidth="100" " Height="
204" ItemsSource="{Binding Path=BannedItems, Mode=TwoWay}"></ListBox>
<Button Name="RemoveBannedItemsButton"
Margin="5"
MinWidth="65"
Height="22"
Click="RemoveBannedItemButton_Click">Remove</Button>
私だけのアイテムtrueとIsEnabled
プロパティ]ボタンをバインドしたいですリストボックスが選択されて、私が試した
XAMLに(集中)
IsEnabled="{Binding ElementName=BannedSourcesListBox, Path=TouchesDirectlyOver.Count}"
しかし、行ってはいけません。