<pre> <TextBlock.Style> <Style TargetType= "TextBlock"> <Setter Property="Foreground" Value="Red" /> <Style.Triggers> <DataTrigger Binding="{Binding IsWorkingStatus}" Value="False"> <Setter Property="Text" Value="True" /> </DataTrigger> </Style.Triggers> </Style> </TextBlock.Style>
public Boolean HRStatus { get; set; }
public Boolean IsWorkingStatus { get { return HRStatus.ToString().Equals("Working") || HRStatus.ToString().Equals("Working - Non Driver"); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)