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

How to expose Read-Only List of Integers

3 Answers 82 Views
PropertyGrid
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Michael asked on 28 Mar 2014, 09:15 PM
Hello,

We have a property to display that is a List{Integer}. This should be a readonly only collection. Is the PropertyGrid smart enough to work with ReadOnlyCollections? Or what sort of DataTemplate magic do we need to do wiring it up?

Similar question for custom types like Enums, or strings, etc.

Thank ye...

Best regards.

3 Answers, 1 is accepted

Sort by
0
Accepted
Dimitrina
Telerik team
answered on 02 Apr 2014, 02:53 PM
Hi Michael,

RadPropertyGrid should display the information from the property List<integer> through a CollectionEditor. You can check our CollectionEditors online documentation for more information.

Regards,
Didie
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Michael
Top achievements
Rank 1
answered on 02 Apr 2014, 03:38 PM
Follow on question, since the property(ies) are readonly, or plausibly the collection(s) themselves are ReadOnlyCollection{int}, for instance, the listing disabled font is a bit light, hard to see. Which property(ies) could we stylize and set to something different? Thank ye...
0
Dimitrina
Telerik team
answered on 07 Apr 2014, 11:08 AM
Hi,

You can try assigning a Style targeting the CollectionEditor element.
For example:
<Style TargetType="telerik:CollectionEditor">
    <Setter Property="FontSize" Value="16"/>
</Style>

Regards,
Didie
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
PropertyGrid
Asked by
Michael
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Michael
Top achievements
Rank 1
Share this question
or