Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1585
Change Text Color in Summary Row only
posted

I am trying to set the Background and Text color of the Summary row for the grid.

I am using this Style

<Style TargetType="ig:CellControl" x:Key="SummaryRowStyle">
<Setter Property="Background" Value="#FF6693CF"/>
 <Setter Property="Foreground" Value="#FFFFFFFF"/>
</Style>

This only changes the Background color, the Text Color is still Black.

How can I achieve this?
Parents
No Data
Reply
  • 1585
    Verified Answer
    posted

    I had to change the default style template as follows to get this to work.

     

    <Setter Property="SummaryDisplayTemplate">
      <Setter.Value>
        <DataTemplate>
          <StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
    <TextBlock Foreground="White"
             Text="{Binding SummaryDefinition.SummaryOperand.RowDisplayLabelResolved}" />
            <TextBlock Foreground="#FFFFFFFF" Text=" = "/>
            <TextBlock Foreground="#FFFFFFFF"
             Text="{Binding Converter={StaticResource SDFormatStringConverter}}"/>
          </StackPanel>
        </DataTemplate>
       </Setter.Value>
    </Setter>
Children
No Data