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
345
XamDataGrid ActiveCell Background
posted

Hi Folks,

I'm styling my XamDataGrid. For some reason active cell has gradient instead of solid brush with a specific background color. Can you help me get active cell background color set to a specific hex?

This is my code: which obviously doesn't work...

        <Style TargetType="{x:Type igDP:DataRecordCellArea}">
            <Setter Property="BackgroundHover" Value="#F7914B"/>
            <Setter Property="BorderHoverBrush" Value="#F7914B"/>
            <Setter Property="BackgroundSelected" Value="#EC660A"/>
            <Setter Property="BackgroundActive" Value="#EC660A"/>
            <Setter Property="BorderBrush" Value="Black"/>
            <Setter Property="BorderThickness" Value="0.5"/>
            <Setter Property="BackgroundAlternate" Value="#bfbfbf"/>
        </Style>

        <Style TargetType="{x:Type igDP:CellPresenter}">
            <Style.Triggers>
                <Trigger Property="IsActive" Value="True">
                    <Setter Property="Background">
                        <Setter.Value>
                            <SolidColorBrush Color="#F7914B"/>
                        </Setter.Value>
                    </Setter> 
                </Trigger>
            </Style.Triggers>
        </Style>

        <Style x:Key="{x:Type igDP:FilterCellValuePresenter}"
                       TargetType="{x:Type igDP:FilterCellValuePresenter}">
            <Setter Property="BorderBrush" Value="Black"/>
            <Setter Property="BorderThickness" Value="0.5"/>
            <Style.Triggers>
                <Trigger Property="HasActiveFilters"
                                 Value="true">
                    <Setter Property="Background">
                        <Setter.Value>
                            <SolidColorBrush Color="#EC660A"/>
                        </Setter.Value>
                    </Setter>
                </Trigger>
            </Style.Triggers>
        </Style>