This is a migrated thread and some comments may be shown as answers.

[Solved] GridViewComboBoxColumn performance

2 Answers 242 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Phillip Garrett
Top achievements
Rank 1
Phillip Garrett asked on 07 Sep 2010, 12:56 PM
Hi,

I'm running into performance issues with GridViewComboBoxColumn.

My scenario (fairly simple grid with 10 columns bound to view model properties):

<Grid>
 <Grid.Resources>
  <viewmodels:ViewModel x:Key="ViewModel" />
 </Grid.Resources>
  
 <telerik:RadGridView 
  x:Name="Grid" 
  DataContext="{Binding Source={StaticResource ViewModel}}" 
  ItemsSource="{Binding Collection}" 
  AutoGenerateColumns="False" 
  ShowGroupPanel="True" 
  ShowInsertRow="True" 
  ActionOnLostFocus="CancelEdit" 
  EditTriggers="CellClick" 
  IsSynchronizedWithCurrentItem="True" 
  DistinctValuesLoading="DistinctValuesLoading" 
  KeyUp="KeyUp" 
  RowValidating="RowValidating" 
  RowValidated="RowValidated" 
  CellValidating="CellValidating" 
  AddingNewDataItem="AddingNewDataItem" 
  BeginningEdit="BeginningEdit" 
  RowEditEnded="RowEditEnded" 
  Filtering="Filtering">
  
  <telerik:RadGridView.Columns>
      
   <telerik:GridViewComboBoxColumn 
    Header="Col1"UniqueName="Col1"
    IsComboBoxEditable="True" 
    DataMemberBinding="{Binding Property1.Id}" 
    ItemsSourceBinding="{Binding Type1Collection, Source={StaticResource ViewModel}}" 
    DisplayMemberPath="Name" 
    SelectedValueMemberPath="Id" />
  
    <telerik:GridViewComboBoxColumn 
     Header="Col2"UniqueName="Col2"
     IsComboBoxEditable="True" 
     DataMemberBinding="{Binding Property2.Id}" 
     ItemsSourceBinding="{Binding Type2Collection, Source={StaticResource ViewModel}}" 
     DisplayMemberPath="Name" 
     SelectedValueMemberPath="Id" />
  
    <telerik:GridViewDataColumn 
     Header="Col3"UniqueName="Col3"
     DataMemberBinding="{Binding Property3}" />
  
    <telerik:GridViewDataColumn 
     Header="Col4"UniqueName="Col4"
     DataMemberBinding="{Binding Property4}" />
  
    <telerik:GridViewDataColumn 
     Header="Col5"UniqueName="Col5"
     DataMemberBinding="{Binding Property5}" />
  
    <telerik:GridViewDataColumn 
     Header="Col6"UniqueName="Col6"
     DataMemberBinding="{Binding Property6}" />
  
    <telerik:GridViewDataColumn 
     Header="Col7"UniqueName="Col7"
     DataMemberBinding="{Binding Property7}" />
  
    <telerik:GridViewComboBoxColumn 
     Header="Col8"UniqueName="Col8"
     IsComboBoxEditable="True" 
     DataMemberBinding="{Binding Property8.Id}" 
     ItemsSourceBinding="{Binding Type3Collection, Source={StaticResource ViewModel}}" 
     DisplayMemberPath="Name" 
     SelectedValueMemberPath="Id" />
  
    <telerik:GridViewComboBoxColumn 
     Header="Col9"UniqueName="Col9"
     IsComboBoxEditable="True" 
     DataMemberBinding="{Binding Property9.Id}" 
     ItemsSourceBinding="{Binding Type4Collection, Source={StaticResource ViewModel}}" 
     DisplayMemberPath="Name" 
     SelectedValueMemberPath="Id" />
  
    <telerik:GridViewDataColumn 
     Header="Col10"UniqueName="Col10"
     DataMemberBinding="{Binding Property10}" />
  
  </telerik:RadGridView.Columns>
 </telerik:RadGridView>
</Grid>

The grid is slow to load, sort, filter, group and scroll (both vertically and horizontally). If I comment out the GridViewComboBoxColumns the grid becomes much quicker. Am I binding correctly with the GridViewComboBoxColumns? something about these controls is very inefficient.

Your help would be appreciated,

Phill

2 Answers, 1 is accepted

Sort by
0
Joachim
Top achievements
Rank 1
answered on 08 Sep 2010, 01:36 PM
Hello,

I have the same problem of performance when i use a GridViewComboBoxColumn.
My scenario is as simple as Philip's scenario.
The grid is very very slow even if i follow all the tips and tricks (like EnableRowVirtualization and EnableColumnVirtualization)...

And that's not all. When the gris is bind to a large amount of data and when the data are grouped (with or without GridViewComboBoxColumn), it's very very slow too (when the data are not grouped  and without a GridViewComboBoxColumn the grid's performances are pretty fine)

Something about GridViewComboBoxColumn is very inefficient, and grouping with a large amount of data too.

Thank you for your help, and sorry for my bad english,

Joachim.
0
Pavel Pavlov
Telerik team
answered on 10 Sep 2010, 12:08 PM
Hi guys,

In our current version of RadGridView the GridViewComboBox column was the only one that did not implement cell element caching . Recently we have implemented this missing optimization , and we expect the fix would significantly increase the performance making it closer ( or the same ) as for the rest of the column types.

The good news is that the fix will be included in the latest internal build (expected later today) .
It will be available for download in your accounts. So please give it a try .

Kind regards,
Pavel Pavlov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
GridView
Asked by
Phillip Garrett
Top achievements
Rank 1
Answers by
Joachim
Top achievements
Rank 1
Pavel Pavlov
Telerik team
Share this question
or