DataTrigger with Value Binding
Posted
by plotnick
on Stack Overflow
See other posts from Stack Overflow
or by plotnick
Published on 2010-05-25T20:38:30Z
Indexed on
2010/05/25
20:41 UTC
Read the original article
Hit count: 309
wpf
|datatrigger
Why this doesn't work?
<Style x:Key="ItemContStyle" TargetType="{x:Type ListViewItem}">
<Style.Triggers>
<DataTrigger Binding="{Binding Path=Asset}"
Value="{Binding RelativeSource={RelativeSource AncestorType={x:Type Window}},
Path=CurrentAsset}">
<Setter Property="Background" Value="Red" />
</DataTrigger>
</Style.Triggers>
© Stack Overflow or respective owner