Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
465
All Rows in one color and childrows in another (in XAML)
posted

Hi,

I have been googleing for long and only can find solution for code behind.

What if I wanted to have all rows in one color and all hierarchical rows in another color in XAML?

Many Thanks,

Houman

 

Parents
  • 69686
    Verified Answer
    posted

    Hello Houman,

    You can try the following style :

     <Style TargetType="{x:Type igDP:DataRecordPresenter}"> 
        <Setter Property="Background" Value="ForestGreen"/> 
            <Style.Triggers> 
              <DataTrigger Binding="{Binding NestingDepth}" Value="0"> 
                 <Setter Property="Background" Value="LightGreen"/> 
              </DataTrigger> 
           </Style.Triggers> 
     </Style>
     

     

Reply Children
No Data