<
telerik:RadGridView.GroupDescriptors
>
<
telerik:GroupDescriptor
Member
=
"Tamcn"
SortDirection
=
"Ascending"
>
<
telerik:GroupDescriptor.AggregateFunctions
>
<
telerik:CountFunction
Caption
=
"Item Count: "
/>
</
telerik:GroupDescriptor.AggregateFunctions
>
</
telerik:GroupDescriptor
>
</
telerik:RadGridView.GroupDescriptors
>
And I need to know how to edit the style... it is showing up as the regular Telerik style (office black) and I have a custom style on my gridview and I need that little piece to look the same. Attached is a screen shot of what I'm talking about.
8 Answers, 1 is accepted
Have you checked the following online help article?
Vanya Pavlova
the Telerik team
Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.
<
Style
TargetType
=
"telerik:GridViewHeaderIndentCell"
>
<
Setter
Property
=
"Background"
Value
=
"{StaticResource GridView_HeaderBackground}"
/>
</
Style
>
This works fine:
<
Style
TargetType
=
"telerik:GridViewFooterCell"
>
<
Setter
Property
=
"Background"
Value
=
"{StaticResource ControlBackgroundNormalGreen}"
/>
</
Style
>
So why doesn't the first one work?
Can you point us to the exact version of RadControls/Silverlight you are currently using? I have performed some tests against Q1 2013 release where everything seems to work correctly.
You may check the attached project for further reference.
Vanya Pavlova
the Telerik team
Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.
<
telerik:IndentPresenter
x:Name
=
"PART_IndentPresenter"
Grid.Row
=
"1"
Grid.Column
=
"1"
MinHeight
=
"{TemplateBinding MinHeight}"
Background
=
"Red"
IndentLevel
=
"{TemplateBinding IndentLevel}"
ItemTemplate
=
"{StaticResource GridViewHeaderIndentCellDataTemplate}"
telerik:SelectiveScrollingGrid.SelectiveScrollingOrientation
=
"Vertical"
/>
And here...
<
DataTemplate
x:Key
=
"GridViewHeaderIndentCellDataTemplate"
>
<
telerik:GridViewHeaderIndentCell
Background
=
"Orange"
/>
</
DataTemplate
>
doesn't work...
Thank you for getting back to us! I can confirm that we had such an issue, where the Background of this element cannot be set with a simple style. For the time being I may suggest you to directly predefine the template of GridViewHeaderIndentCell and modify its Background from there, as follows:
<
SolidColorBrush
x:Key
=
"GridView_HeaderInnerBorder"
Color
=
"#FF4B4B4B"
/>
<
SolidColorBrush
x:Key
=
"GridView_HeaderRowOuterBorder"
Color
=
"#FF848484"
/>
<
SolidColorBrush
x:Key
=
"GridView_HeaderRowBackground"
Color
=
"Red"
/>
<
Style
TargetType
=
"telerik:GridViewHeaderIndentCell"
>
<
Setter
Property
=
"Template"
>
<
Setter.Value
>
<
ControlTemplate
TargetType
=
"telerik:GridViewHeaderIndentCell"
>
<
Border
x:Name
=
"OuterBorder"
BorderBrush
=
"{TemplateBinding BorderBrush}"
BorderThickness
=
"{TemplateBinding BorderThickness}"
HorizontalAlignment
=
"{TemplateBinding HorizontalContentAlignment}"
Padding
=
"{TemplateBinding Padding}"
VerticalAlignment
=
"{TemplateBinding VerticalContentAlignment}"
Width
=
"25"
>
<
Border
x:Name
=
"InnerBorder"
BorderBrush
=
"{StaticResource GridView_HeaderInnerBorder}"
BorderThickness
=
"1"
Background
=
"{TemplateBinding Background}"
/>
</
Border
>
</
ControlTemplate
>
</
Setter.Value
>
</
Setter
>
<
Setter
Property
=
"BorderThickness"
Value
=
"0 0 1 1"
/>
<
Setter
Property
=
"BorderBrush"
Value
=
"{StaticResource GridView_HeaderRowOuterBorder}"
/>
<
Setter
Property
=
"Background"
Value
=
"{StaticResource GridView_HeaderRowBackground}"
/>
<
Setter
Property
=
"VerticalContentAlignment"
Value
=
"Stretch"
/>
<
Setter
Property
=
"HorizontalContentAlignment"
Value
=
"Stretch"
/>
<
Setter
Property
=
"Padding"
Value
=
"0"
/>
</
Style
>
Would it be possible to try with this one and let me know how it goes?
Kind regards,
Vanya Pavlova
the Telerik team
Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.
It looks like my only option is to hide the indent cell and set the indent on the content to zero so it still lines up with the regular column headers. This should work okay since I'm setting the groupings and they cannot be changed by the user, but it would be nice to be able to go to the latest version so the simple style would work. Its just that my users don't have silverlight 5...