【发布时间】:2010-06-22 06:00:28
【问题描述】:
MSDN 说http://msdn.microsoft.com/en-us/library/ms256086.aspx
degree[@from != "Harvard"] - from 属性不等于 "Harvard" 的所有元素。
但是当尝试在我的 xaml 代码中实现这一点时,它会导致错误,因为在 XAML 语法中,所有值元素都应该放在引号中,我该如何解决这个问题?
<ComboBox ItemTemplate="{StaticResource rolelistTemplate}" ItemsSource="{Binding XPath=/EssenceList/Essence[@Type="Role"]}" IsSynchronizedWithCurrentItem="True"/>
我也试过这个,但它也给我语法错误
<ComboBox ItemTemplate="{StaticResource rolelistTemplate}" ItemsSource="{Binding XPath=/EssenceList/Essence[@Type='Role']}" IsSynchronizedWithCurrentItem="True" />
【问题讨论】: