void CustomRowAppearance(object sender, CustomRowAppearanceEventArgs e)
 {
     if (e.RowSelectionState != SelectionState.None)
     {
         object result = e.ConditionalValue;
         if (e.Property == TextBlock.ForegroundProperty || e.Property == TextBlock.BackgroundProperty)
         {
             SolidColorBrush original    = e.OriginalValue as SolidColorBrush;
             SolidColorBrush conditional = e.ConditionalValue as SolidColorBrush;
             if (conditional != null && (original == null || original.Color != conditional.Color))
             {
                 result = ShadeBrush(conditional);
             }
         }
         e.Result  = result;
         e.Handled = true;
     }
 }
 private void viewAccountTax_CustomRowAppearance(object sender, CustomRowAppearanceEventArgs e)
 {
     e.Result  = e.ConditionalValue;
     e.Handled = true;
 }