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

Optimizing RadGridView

3 Answers 232 Views
GridView
This is a migrated thread and some comments may be shown as answers.
wpfPerf
Top achievements
Rank 1
wpfPerf asked on 16 Feb 2010, 09:29 PM
I'm looking for any guidelines for optimization of the RadGridView.  Specifically, I'd like to know if such documentation exists which specifies grid options which might be "performance-heavy".  Even though you can load millions of rows into the grid, you still see [the familiar WPF] large spikes in CPU.   I'm interested in turning off all non-essential functions to get more performance out of the grid, and am looking for features or settings which ppl. feel helped the overall performance.   So far I turned off sorting, highlighting/selection, etc.  Each helps / just looking for a general set of principles to really optimize perf.

3 Answers, 1 is accepted

Sort by
0
wpfPerf
Top achievements
Rank 1
answered on 16 Feb 2010, 09:35 PM
there were 7 people reading this within 30 seconds.  that's pretty good.  :) 

UPDATE:  I see dependencyProps heavily utilized... using WPFToolkit w/ extremely similar setup I do not see depProp spike.  That may be one area to improve upon & I'll research it.   Any others are much appreciated.
0
Hristo
Telerik team
answered on 17 Feb 2010, 05:35 PM
Hello wpfPerf,

In general, the fastest performance can be achieved if you bind to a simple property because we will use lambda to get the value. If you bind to complex property (sub property) we have to use bindings to get the value for the cell. Using bindings is much slower then lambdas.

Next thing that will slow you is using converter. If there is a converter we will call it.

General performance tip is not to place RadGridView in controls/panels which will measure it with infinity.
For example: ScrollViewer, StackPanel and Grid with Row.Height=Auto or Column.Width=Auto  will measure with infinity. If RadGridView is measured with infinity the virtualization turns off.
Also setting RadGridView.ColumnWidth to a specific width (like 100) will increase both horizontal & vertical scrolling performance. Auto is a little bit slower and Star is the slowest (most noticeable when you have a lot of columns)

If applicable, try to stick to the default templates and avoid overriding templates of rows and cells.


Sincerely yours,
Hristo
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.
0
wpfPerf
Top achievements
Rank 1
answered on 18 Feb 2010, 03:46 AM
This is perfect; really appreciate the feedback...yes, using simple props right now + not in stackPanel, etc.   I'll make sure to try all settings tomorrow - thank you.
Tags
GridView
Asked by
wpfPerf
Top achievements
Rank 1
Answers by
wpfPerf
Top achievements
Rank 1
Hristo
Telerik team
Share this question
or