RadGridView RowDetails Style tune

6 posts, 0 answers
  1. Haythem
    Haythem avatar
    26 posts
    Member since:
    Jun 2013

    Posted 17 Oct 2013 Link to this post

    Hi again,
    I have an issue concerning a border in my radGridViewRowDetail style.
    I changed the backGround to grey but i couldn't delete this border after expanding the row details...
    I edited a copy of the gridView style in blend but couldn't find the proprty to change or to delete to i can get my aim.
    I need your help please.
    i joined an image containing more details about this issue.

    Thank's in advance
    Haythem KAROUI
    CREA DIGITAL
  2. Yoan
    Admin
    Yoan avatar
    1066 posts

    Posted 21 Oct 2013 Link to this post

    Hi Haythem,

    I would suggest you to check this help article which demonstrates how to style the RowDetails.

    I hope this helps.

    Regards,
    Yoan
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. DevCraft banner
  4. Haythem
    Haythem avatar
    26 posts
    Member since:
    Jun 2013

    Posted 07 Nov 2013 Link to this post

    Hi again,
    actually the previous article didn't show me how to get these :
    • ControlOuterBorder - a brush that represents the outer border color of the details container.
    • DetailsPresenterTemplate - the ControlTemplate, applied to the DetailsPresenter control. 
    I tried Edit Template on blend but the control template generated is empty .
    What can i do please? 

    Regards,
    Haythem KAROUI
    CREA DIGITAL

  5. Haythem
    Haythem avatar
    26 posts
    Member since:
    Jun 2013

    Posted 07 Nov 2013 Link to this post

    Hi,
     am sorry for the double post that was a missclick.

    Waiting forward for your answer.
    KAROUI Haythem
    CREA-DIGITAL
  6. Vanya Pavlova
    Admin
    Vanya Pavlova avatar
    2019 posts

    Posted 08 Nov 2013 Link to this post

    Hello Haythem,


    You may always get the desired style from the Themes folder of your personal installation for the corresponding theme. You can find below the default template of DetailsPresenter against Office_Black theme: 

    <SolidColorBrush x:Key="ControlOuterBorder" Color="#FF848484"/>
        <ControlTemplate x:Key="DetailsPresenterTemplate" TargetType="telerik:DetailsPresenter">
            <Border x:Name="DetailsBorder" BorderBrush="{StaticResource ControlOuterBorder}" BorderThickness="0 1">
                <VisualStateManager.VisualStateGroups>
                    <VisualStateGroup x:Name="DetailsStates">
                        <VisualState x:Name="DetailsVisible">
                            <Storyboard>
                                <ObjectAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DetailsBorder">
                                    <DiscreteObjectKeyFrame KeyTime="0">
                                        <DiscreteObjectKeyFrame.Value>
                                            <Visibility>Visible</Visibility>
                                        </DiscreteObjectKeyFrame.Value>
                                    </DiscreteObjectKeyFrame>
                                </ObjectAnimationUsingKeyFrames>
                            </Storyboard>
                        </VisualState>
                        <VisualState x:Name="DetailsCollapsed"/>
                    </VisualStateGroup>
                </VisualStateManager.VisualStateGroups>
                <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}">
                    <ContentPresenter x:Name="PART_ContentPresenter" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                </Border>
            </Border>
        </ControlTemplate>
        <LinearGradientBrush x:Key="GridView_RowDetailsBackground" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FFC2C2C2"/>
            <GradientStop Color="#FFF0F0F0" Offset="0.3"/>
        </LinearGradientBrush>
        <SolidColorBrush x:Key="ControlInnerBorder" Color="White"/>
        <Style x:Key="DetailsPresenterStyle1" TargetType="telerik:DetailsPresenter">
            <Setter Property="Template" Value="{StaticResource DetailsPresenterTemplate}"/>
            <Setter Property="Visibility" Value="Collapsed"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Background" Value="{StaticResource GridView_RowDetailsBackground}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ControlInnerBorder}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="Padding" Value="0"/>
            <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
        </Style>


    Hope this helps! 


    Regards,
    Vanya Pavlova
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  7. Haythem
    Haythem avatar
    26 posts
    Member since:
    Jun 2013

    Posted 11 Nov 2013 Link to this post

    Thank you for your answer,
    after setting the template the RowDetail proprty ControlOuterBorder is seen by the style the way i can modify it ...

    Best Regards,
    KAROUI Haythem
    CREA-DIGITAL
Back to Top
DevCraft banner