This is a migrated thread and some comments may be shown as answers.
Class with indexed property
10 Answers 45 Views
This is a migrated thread and some comments may be shown as answers.
Nohinn
Top achievements
Rank 1
Nohinn asked on 02 May 2011, 04:29 PM
Is there any chance to make the expression editor work with a class that it's properties are stored in a dictionary accessible through indexed properties?

10 Answers, 1 is accepted

Sort by
0
Yavor Georgiev
Telerik team
answered on 03 May 2011, 05:41 PM
Hi Nohinn,

 Could you please elaborate on your question?

 RadExpressionEditor can parse access to indexers in the following form - propertyName[indexerKey].

Greetings,
Yavor Georgiev
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
Nohinn
Top achievements
Rank 1
answered on 03 May 2011, 06:30 PM
yeah I have tried that.
But what I want to know is if it would be possible to just have the existing keys as fields like if they were properties of the item that uses the expression editor.
And then just writing

"Property1 > 0"

Would look inside the dictionary for that key, get the value and check if it is greater than 0 for example.
Because the user doesn't have any info about what name I used in code for the dictionary property.
0
Yavor Georgiev
Telerik team
answered on 03 May 2011, 06:37 PM
Hello Nohinn,
 
 I'm sorry, but we don't plan on supporting such scenarios internally. We do, however, plan on supporting dynamic types (e.g. ExpandoObject), which I believe can work with your scenario.

Regards,
Yavor Georgiev
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
Denis Vuyka
Top achievements
Rank 1
answered on 07 Jun 2011, 01:24 PM
Hello,
What is the state of DynamicObject support?
Thanks in advance,
Denis
0
Yavor Georgiev
Telerik team
answered on 07 Jun 2011, 01:39 PM
Hi Denis,

 Thank you for your interest in RadExpressionEditor.

 We will introduce support for binding to dynamic objects in RadGridView with our next release, which is expected in mid-July. Unfortunately, tight deadlines preclude us from enabling dynamics support in RadExpressionEditor in this release, but this feature is on our internal roadmap and will be introduced in a subsequent release.

All the best,
Yavor Georgiev
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
Denis Vuyka
Top achievements
Rank 1
answered on 07 Jun 2011, 01:48 PM
Hi Yavor,
Thanks for the quick reply. The control is great and we already have variety of scenarios where it fits and saves us a lot of time. 
Denis
0
Nathaniel
Top achievements
Rank 1
answered on 07 Nov 2011, 09:15 PM
When might we see enabling dynamics support in RadExpressionEditor?
0
Vlad
Telerik team
answered on 10 Nov 2011, 04:34 PM
Hi,

 We will do our best to include this in the first service pack of our upcoming Q3 2011 release. 

Kind regards,
Vlad
the Telerik team

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

0
KJ
Top achievements
Rank 1
answered on 04 Jun 2014, 02:01 PM
Could you provide a sample? I can't get indexed properties to work, I've tried several types, i.e. List, Dictionary.

In the online example I tried the expression "Discontinued.ToString().ToCharArray()[0]". This gives a blank preview, while i was expecting "T" or "F", from the boolean value it started with.
Up until the index at the end it gives the expected result, the result of ToString() of the last part of the expression.

Thank you.

0
Dimitrina
Telerik team
answered on 05 Jun 2014, 02:37 PM
Hello,

You could actually access the first char like so:
Discontinued.ToString().ToCharArray().ElementAt(0)

I hope this helps.

Regards,
Didie
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Asked by
Nohinn
Top achievements
Rank 1
Answers by
Yavor Georgiev
Telerik team
Nohinn
Top achievements
Rank 1
Denis Vuyka
Top achievements
Rank 1
Nathaniel
Top achievements
Rank 1
Vlad
Telerik team
KJ
Top achievements
Rank 1
Dimitrina
Telerik team
Share this question
or