Merge RowStyleSelector, with GridViewStyle

2 posts, 0 answers
  1. John
    John avatar
    32 posts
    Member since:
    Sep 2011

    Posted 13 Oct 2011 Link to this post

    I have a grid and I need to have this style:

    <Style x:Key="ShowroomLogGridViewRowStyle" TargetType="telerik:GridViewRow">
                <Setter Property="Template" Value="{StaticResource GridViewRowTemplate}"/>
    </Style>

    merge with this:
    <View:ColorStyle x:Key="colorStyle">
              <View:ColorStyle.YellowStyle>
                  <Style TargetType="telerik:GridViewRow">
                      <Setter Property="Background" Value="Yellow"/>
                  </Style>
              </View:ColorStyle.YellowStyle>
              <View:ColorStyle.TransparentStyle>
                  <Style TargetType="telerik:GridViewRow">
                      <Setter Property="Background" Value="Transparent" />
                  </Style>
              </View:ColorStyle.TransparentStyle>
              <View:ColorStyle.LightBlueStyle>
                  <Style TargetType="telerik:GridViewRow">
                      <Setter Property="Background" Value="#648CB2FC" />
                  </Style>
              </View:ColorStyle.LightBlueStyle>
              <View:ColorStyle.LightGreenStyle>
                  <Style TargetType="telerik:GridViewRow">
                      <Setter Property="Background" Value="#6470C950" />
                  </Style>
              </View:ColorStyle.LightGreenStyle>
          </View:ColorStyle>

    Could you give me some hints to deal with this?

    Best regards,

    John
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 13 Oct 2011 Link to this post

    Hi John,

    I'm not sure I understand your question. You can return this style using the grid RowStyleSelector.

    All the best,
    Vlad
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Back to Top