or




SelectionResultRadGridView.ViewRowFormatting += SelectionResultRadGridViewViewRowFormatting;SelectionResultRadGridView.CellClick += SelectionResultRadGridViewCellClick;private static void SelectionResultRadGridViewViewRowFormatting(object sender, RowFormattingEventArgs e){ if (e.RowElement.RowInfo is GridViewGroupRowInfo && e.RowElement.RowInfo.ChildRows.Any(x => x.IsSelected)) { e.RowElement.DrawFill = true; e.RowElement.BackColor = Color.FromArgb(255,216,132); e.RowElement.GradientStyle = GradientStyles.Solid; } else { e.RowElement.ResetValue(LightVisualElement.DrawFillProperty, ValueResetFlags.Local); e.RowElement.ResetValue(LightVisualElement.BackColorProperty, ValueResetFlags.Local); e.RowElement.ResetValue(LightVisualElement.NumberOfColorsProperty, ValueResetFlags.Local); e.RowElement.ResetValue(LightVisualElement.ForeColorProperty, ValueResetFlags.Local); }}void SelectionResultRadGridViewCellClick(object sender, GridViewCellEventArgs e){ if (e.Row.RowElementType == typeof(GridGroupHeaderRowElement)) { foreach (var childRow in e.Row.ChildRows) { childRow.IsSelected = true; } } foreach (DataGroup group in SelectionResultRadGridView.Groups) { group.GroupRow.InvalidateRow(); }}