When using a QueryableCollectionView with a FilterDescriptor and a GroupDescriptor, items which are filtered won't be added to the (new) group after being edited programmatically.
For the time being, the Refresh method of the view can be called to reevaluate this or the filter descriptor can be removed and re-added.
QueryableEntityCoreCollectionView internal collections not in sync.
Currently, there is no workaround to this behavior.
GridView allows you to define an AggregateFunction for each column and display the summary information for all cells in the column when there is grouping enabled. This will produce a group header with an aggregate result for each column that has aggreagate functions defined.
Adding and removing columns from the RadGridView's Columns collection doesn't update the aggregate results displayed in the group header.
To work this around, you can remove the GroupDescriptor from the GridView control and add a new instance of the descriptor, when you add/remove an item.
private void RadButton_Click_1(object sender, RoutedEventArgs e)
{
var column = new GridViewDataColumn() { DataMemberBinding = new System.Windows.Data.Binding("Number1") };
column.AggregateFunctions.Add(new SumFunction());
this.gridView.Columns.Add(column);
var descriptor = (GroupDescriptor)this.gridView.GroupDescriptors[0];
this.gridView.GroupDescriptors.Remove(descriptor);
this.gridView.GroupDescriptors.Add(new GroupDescriptor() { Member = descriptor.Member });
}
Calling the BeginInsert() method of RadGridView, adds a new row at the bottom of the items and scrolls to the newly added row. However, if the vertical scrollbar is not visible and the newly added row makes the viewport so big that the scrollbar should display, the row gets clipped. Also, the vertical scrollbar that was just added is not scrolled to the bottom, which is actually why the row is clipped. Each next insert (after the scrollbar gets visible) will display the added row properly.
To work this around, you can scroll the vertical scrollbar manually to bottom.
private void BeginInsertRow()
{
var scrollViewer = this.gridView.FindChildByType<GridViewScrollViewer>();
bool requestScrollToBottom = false;
if (scrollViewer.ComputedVerticalScrollBarVisibility == Visibility.Collapsed)
{
var panel = this.gridView.FindChildByType<GridViewVirtualizingPanel>();
var sumHeight = (source.Count + 1) * this.gridView.RowHeight;
requestScrollToBottom = sumHeight > panel.ActualHeight;
}
this.gridView.BeginInsert();
if (requestScrollToBottom)
{
scrollViewer.ScrollToBottom();
}
}
When a RadGridView cell has a validation error, a red border will appear around the cell. In this case, the top validation border is missing on the first row cells. As a workaround, you can move the ContentPresenters of the cells a little bit in the loaded event of the control.
private void RadGridViewView_Loaded(object sender, System.Windows.RoutedEventArgs e)
{
var treeListView = sender as RadTreeListView;
var editorPresenters = treeListView.ChildrenOfType<ContentControl>().Where(x => x.Name == "PART_ContentPresenter" && x.ParentOfType<GridViewCell>() != null);
foreach (var item in editorPresenters)
{
item.Margin = new System.Windows.Thickness(1);
}
}
As a user I would like to have Unfocused state for selected GridViewCells when SelectionMode="Cell". Similar to the Unfocused state for selected GridViewRows (you can check this article as a reference: http://www.telerik.com/help/wpf/gridview-selection-unfocused-state.html).