Performance of RadPropertyGrid

3 posts, 0 answers
  1. sprucely
    sprucely avatar
    13 posts
    Member since:
    Feb 2010

    Posted 10 Nov 2011 Link to this post

    I just updated to the latest version of WPF controls from RadControls_for_WPF40_2011_2_0920_Dev_hotfix.zip and decided to try out the PropertyGrid. I'm not planning on using the autogenerate feature, but thought it might be helpful to point out what I noticed.

    Each time I change objects in the Item property, my application becomes unresponsive for a few seconds, and memory usage goes up by anywhere from 20 MB to 200 MB. It never runs out of memory, because it appears in ProcessExplorer to be reclaimed as soon as it hits the memory ceiling. When it is finished, it displays the 30 to 50 properties on my objects. But it does not provide any expanders to view properties of nested objects. (EDIT: I just noticed the NestedPropertiesVisibility setting)

    It appears that most of the time is spent in Type.GetProperties() after about ten recursive calls to GenerateNestedPropertyDefinitions(). You might benefit from using some caching so that you don't have to make so many calls to Type.GetProperties(). Maybe something like the TypeInfoCache from http://www.codeproject.com/KB/cs/generaldynamicobjectproxy.aspx. And maybe find a way to perform the property searches on a background thread.
  2. sprucely
    sprucely avatar
    13 posts
    Member since:
    Feb 2010

    Posted 10 Nov 2011 Link to this post

    When I expand some properties, I sometimes get exceptions from it attempting to create two-way bindings on read-only properties.
  3. UI for WPF is Visual Studio 2017 Ready
  4. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1127 posts

    Posted 11 Nov 2011 Link to this post

    Hello Sprucely,

    Our initial approach to nested properties has proved to be quite memory consuming when items with deep property hierarchies are being processed. So that we have introduced a default "load on demand" behavior, in order to cut any excessive memory usage. This feature is available with October's internal builds. I would advise you to test it with our latest internal build or you may wait several days for our official Q3 release?

    All the best,
    Ivan Ivanov
    the Telerik team
    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Back to Top