views:

33

answers:

0

Hi I have a Data Trigger in a style targeting a TextBlock where I am trying to change the Text and background of a TextBlock

<DataTrigger Binding="{Binding ElementName=..., Path=IsVisible}" Value="False">
   <DataTrigger.Setters>
      <Setter Property="Text" Value="Collaps"></Setter>
      <Setter Property="Background" Value="Something"></Setter>
   </DataTrigger.Setters>
</DataTrigger>

When the Trigger fires the Background updates but the Text does not change.

Is there a reason why I cant change the Text Property? It is a dependency property as far as I know.