Abs*_*tor 3 wpf xaml dependency-properties
<Style TargetType="controls:EventTimeView">
<Style.Triggers>
<Trigger Property="PositioningMethod" Value="Column" >
<Setter Property="Background" Value="Black" />
</Trigger>
</Style.Triggers>
</Style>
Run Code Online (Sandbox Code Playgroud)
PositioningMethod是枚举类型的EventTimeView的依赖项属性.
结果是:
System.InvalidOperationException occurred
Message=Property can not be null on Trigger.
Source=PresentationFramework
StackTrace:
at System.Windows.StyleHelper.UpdateTables(PropertyValue& propertyValue, FrugalStructList`1& childRecordFromChildIndex, FrugalStructList`1& triggerSourceRecordFromChildIndex, FrugalStructList`1& resourceDependents, HybridDictionary& dataTriggerRecordFromBinding, HybridDictionary childIndexFromChildName, Boolean& hasInstanceValues)
InnerException:
Run Code Online (Sandbox Code Playgroud)
我不知道可能出错了什么.例外太模糊了:哪个属性?什么是null?
| 归档时间: |
|
| 查看次数: |
2594 次 |
| 最近记录: |