PropertyGrid Binding to a Collection?

6 posts, 0 answers
  1. Scott
    Scott avatar
    8 posts
    Member since:
    Aug 2011

    Posted 07 May 2012 Link to this post

    Can the PropertyGrid Bind to a collection?

    I have a collection of System Settings I would like to bind to a property Grid?  Is this possible with your property grid control?

    All I see in examples are binding to a single item.

    Thanks,
    Scott
  2. Pavel Pavlov
    Admin
    Pavel Pavlov avatar
    2039 posts

    Posted 08 May 2012 Link to this post

    Hello Scott,

    The standard approach to define what to view and edit in RadPropertyGrid is to define a PropertyDefinition for each field you need to edit.

    In your case you will need to iterate your original collection and add a PropertyDefinition with the relevant binding for each position in this collection.

    Let me know if you have troubles while implementing this approach.


    Greetings,
    Pavel Pavlov
    the Telerik team
    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
  3. DevCraft banner
  4. Saranya
    Saranya avatar
    5 posts
    Member since:
    Jun 2012

    Posted 29 Jun 2012 Link to this post

    Hi Pavel

                     Will you please post an example for your above explanation about PropertyGrid Bind to a collection(arraylist--is my need )?


    Thanks
    Saranya..
  5. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1127 posts

    Posted 29 Jun 2012 Link to this post

    Hi Saranya,

    The basic idea behind RadPropertyGrid is to provide an interface for visualizing and editing of an item's properties. There are some scenarios, in which a common set of properties should be extracted from a collection of items. Here is an article that illustrates a specific feature of RadPropertyGrid that handles such cases. RadPropertyGrid also supports editing of collection-type properties utilizing the CollectionEditorPicker control. Please refer to the mentioned articles and let us know whether your case is similar to any of the described scenarios. If not, it might be much more convenient for you to consider some of our ItemsControl-based controls.

    Greetings,
    Ivan Ivanov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  6. Saranya
    Saranya avatar
    5 posts
    Member since:
    Jun 2012

    Posted 02 Jul 2012 Link to this post

    Hi Ivan
              Thanks for the reply.CollectionEditorPicker control is fine for my requirement.But am not able to add that control to my silverlight page.am getting error like assembly is missing.this particular control i can find in RadControls for Silverlight Q2 2012 release right ?  i don't find any working demo for this control inside property grid.i need some working demo and namespace details.


    Thanks
    Saranya

  7. Ivan Ivanov
    Admin
    Ivan Ivanov avatar
    1127 posts

    Posted 02 Jul 2012 Link to this post

    Hello,

    I have prepared a sample project for you that illustrates how to use CollectionEditorPicker both in RadPropertyGrid and stand-alone. Please, refer to the attachment.

    Kind regards,
    Ivan Ivanov
    the Telerik team
    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Back to Top
DevCraft banner