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

Custom DataFormDataField and DisplayOrder

3 Answers 94 Views
DataForm
This is a migrated thread and some comments may be shown as answers.
Dragon Curve
Top achievements
Rank 1
Dragon Curve asked on 07 Jun 2011, 02:29 PM
Hi all,

I've created a custom DataFormDataField so I can create an auto-generated field that uses RadMaskedTextBox (for percentages).

This has been all fine apart from the fact, in someone's infinite wisdom, they've made DisplayOrder internal.  This means that now my overriden field always appears at the very top of the form, which is far, far from desirable.

I can't possibly understand why every other field would be public apart from DisplayOrder, but it's really throwing a spanner in the works.

Surely this is a bug or an oversight?  Can someone from Telerik comment?

3 Answers, 1 is accepted

Sort by
0
Pavel Pavlov
Telerik team
answered on 10 Jun 2011, 01:36 PM
Hello Dragon Curve,

It seems you have hit a known bug - when giving a new field in the AutoGenerating event , the order was reset. This was already fixed , so an upgrade to the latest internal build should solve the problem. The LIB should be available for download in your account.

Additionally upgrading to the latest LIb will give you a bit more control over the order.  You may find a new property in the event args allowing to set the desired order inside the autogenerating event handler.

As a side note :

The DisplayOrder property of the field is intentionally not exposed as public. Part of the reasoning is that fields may be defined manually. When defining manually the developer may place them in any layout (e.g. Grid panels, stack panels , horizontally, vertically etc. ) . In such scenario the DisplayOrder does not make any sense , as the order of appearance is defined by the layout panels involved and the XAML used.

That is why we have exposed the property in the autogenerating event args  - the order makes sense only in the context of auto generated fields .

Hope that helps.

Regards,
Pavel Pavlov
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
Martin
Top achievements
Rank 1
answered on 15 Jun 2011, 06:01 PM
I am facing the issue. Can I also get access to the LIB.

Martin
0
Hristo
Telerik team
answered on 16 Jun 2011, 08:54 AM
Hi Martin,

You can download the latest internal build from here.

Kind regards,
Hristo
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
Tags
DataForm
Asked by
Dragon Curve
Top achievements
Rank 1
Answers by
Pavel Pavlov
Telerik team
Martin
Top achievements
Rank 1
Hristo
Telerik team
Share this question
or