I setup grid using code by setting column/row properties of the field class. In the first row I get a white space. I expected gray space as the last row. Suggestions?
Thanks
Hi I am facing some issue related to header BG Color/ Hover color but i am not able to change color code of header, I am doing like this
<Style TargetType="igDP:DataRecordPresenter" x:Key="DataRecordPresenter1"> <Setter Property="HeaderAreaBackground" Value="#FFECE9D8"> </Setter> <Setter Property="Foreground" Value="#FFECE9D8"> </Setter> <Setter Property="Background" Value="#FFECE9D8"> </Setter> </Style>
<igDP:XamDataGrid.FieldLayoutSettings > <igDP:FieldLayoutSettings AutoGenerateFields="False" RecordSelectorLocation="None" DataRecordPresenterStyle="{StaticResource ResourceKey=DataRecordPresenter1}" DataRecordCellAreaStyle="{StaticResource customRecordArea}"/> </igDP:XamDataGrid.FieldLayoutSettings>
But only color of most left column is changed but other remain same colr, plz suggest where am i doing wrong?
You can just change the white gradient or use BasedOn to get this class from a specific theme. BasedOn syntax looks like this:
BasedOn="{x:Static igThemes:DataPresenterOnyx.DataRecordPresenter}", where of cource the igThemes is namespace to our themes.
That also changed the left most part of the header and the gray area. Also is there a way to use current theme? User is able to change theme.
Hello,
This is because the Gradient of the default theme is white in this area. You can change this by creating a style for the DataRecordPresenter and setting the HeaderAreaBackground property:
<Style TargetType="igDP:DataRecordPresenter">
<Setter Property="HeaderAreaBackground">
<Setter.Value>
<LinearGradientBrush StartPoint="0,0" EndPoint="0,1">
<GradientStop Offset="0.000000" Color="#FF828796"/>
<GradientStop Offset="0.5" Color="Blue"/>
<GradientStop Offset="0.5" Color="#FF303342"/>
<GradientStop Offset="1.000000" Color="Yellow"/>
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Style>
Hope this helps