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

Multi-selection in PropertyGrid

1 Answer 106 Views
PropertyGrid
This is a migrated thread and some comments may be shown as answers.
Dodd
Top achievements
Rank 1
Dodd asked on 13 Aug 2013, 04:39 AM
Hi,
I'm trying to use multi-seleciton in PropertyGrid and the following problems occurred:

1. When I set SelectionMode to multi in Xaml and try to switch it to Single mode in code-behind, it doesn't work.
2. When I set NestedPropertiesVisibility="Visible", it worked fine in the single selection mode, but doesn't work in the multi selection mode.
3. Data Annotations set in the Display attriute doesn't work.
3. DataTemplateSelection does not work properly as in the single selection. For example, I get
PropertyType : {Name = "Object" FullName = "System.Object"} System.Type {System.RuntimeType}
for the code below.

public class PropertyGridDataTemplateSelector : DataTemplateSelector
    {
        public override DataTemplate SelectTemplate(object item, DependencyObject container)
        {
            if (item as PropertyDefinition != null && (item as PropertyDefinition).SourceProperty.PropertyType == typeof(Int32))
            {
                return IntegerPropertyDataTemplate;
            }
            return null;
        }

        public DataTemplate IntegerPropertyDataTemplate { get; set; }
    }

Can you get this fixed?
Thanks!

1 Answer, 1 is accepted

Sort by
0
Maya
Telerik team
answered on 14 Aug 2013, 02:26 PM
Hello Dodd,

I have tested all issues you listed below, but was not able to reproduce any of them. Could you take a look at the sample attached and let me know whether I am missing something ?  

Regards,
Maya
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
PropertyGrid
Asked by
Dodd
Top achievements
Rank 1
Answers by
Maya
Telerik team
Share this question
or