Rowstyle of a grouped Row

4 posts, 1 answers
  1. Roman Wack
    Roman Wack avatar
    13 posts
    Member since:
    Mar 2010

    Posted 16 Feb 2011 Link to this post

    Hi,
    can anybody tell me, how do change the marked Border in my attachment? It isn't affected by RowStyle, AlternateRowStyle and GroupRowStyle

    Thank you!
  2. Answer
    Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 16 Feb 2011 Link to this post

    Hi Roman,

     
    This part is called GridViewIndentCell and you can change its background by creating a simple style in this way:

    <UserControl
        x:Class="SilverlightApplication39.MainPage"
        Width="640" Height="480">
    <UserControl.Resources>
        <Style TargetType="telerik:GridViewIndentCell">
            <Setter Property="Background" Value="Red"/>
            <Setter Property="BorderBrush" Value="Blue"/>
            </Style>
        </UserControl.Resources>
        <Grid x:Name="LayoutRoot" Background="White" DataContext="{Binding Source={StaticResource SampleDataSource}}">
            <telerik:RadGridView Margin="48,24,64,56" ItemsSource="{Binding Collection}"/>
        </Grid>
    </UserControl>

    If this style does not meet your personal requirements, you need to edit its template and change it in the way you need. In RadGridView there are four elements which represent indentation of their parent elements:
     
    GridViewIndentCell - represents the Indent of a GridViewRow
    GridViewHeaderIndentCell - represents the indent of GridViewHeaderRow
    GridViewGroupFooterIndentCell - represents the indent of GridViewGroupFooterRow
    GridViewFooterIndentCell - represents the indent of the GridViewFooterRow


    Within the templates of GridViewRow, GridViewHeaderRow, GridViewGroupFooterRow and GridViewFooterRow they are represented by the following part, which is called PART_IndentPresenter.
    You can read more about this in our online documentation, please follow this link.

    If you need any further assistance, please let me know.


    Best wishes,
    Vanya Pavlova
    the Telerik team
  3. Roman Wack
    Roman Wack avatar
    13 posts
    Member since:
    Mar 2010

    Posted 16 Feb 2011 Link to this post

    Thank you very much!
  4. atran
    atran avatar
    12 posts
    Member since:
    Feb 2010

    Posted 31 May 2012 Link to this post

    Roman,
       How did you get your grouped row details to align with columns?  Please advise
Back to Top