The xamDataPresenter™ and xamDataGrid™ controls display special records when you enable the ability to add new records, filter records, and/or summarize records. If you place all three of these special records in the same location such as the top of the control, xamDataPresenter and xamDataGrid the summary record first, followed by the filter record, which is then followed by the add new record. However, you can customize the order of these special records by creating a SpecialRecordOrder object and setting the SpecialRecordOrder property of a FieldLayoutSettings object.
The SpecialRecordOrder object exposes three properties that correspond to one of the three special records. You can define the order of the special records by setting each property to an integer value. The special record with the lowest value will be first while the special record with the highest value will be last.
The following example code demonstrates how to modify the order of the add record, filter record, and summary record.
<igDP:XamDataPresenter Name="xamDataPresenter1">
<igDP:XamDataPresenter.FieldLayoutSettings>
<igDP:FieldLayoutSettings>
<igDP:FieldLayoutSettings.SpecialRecordOrder>
<igDP:SpecialRecordOrder AddRecord="0" FilterRecord="1" SummaryRecord="2" />
</igDP:FieldLayoutSettings.SpecialRecordOrder>
</igDP:FieldLayoutSettings>
</igDP:XamDataPresenter.FieldLayoutSettings>
</igDP:XamDataPresenter>
Imports Infragistics.Windows.DataPresenter
...
Dim recordOrder As New SpecialRecordOrder With {.AddRecord = 0, .FilterRecord = 1, .SummaryRecord = 2}
Me.xamDataPresenter1.FieldLayoutSettings.SpecialRecordOrder = recordOrder
using Infragistics.Windows.DataPresenter;
...
SpecialRecordOrder recordOrder = new SpecialRecordOrder
{
AddRecord = 0,
FilterRecord = 1,
SummaryRecord = 2
};
this.xamDataPresenter1.FieldLayoutSettings.SpecialRecordOrder = recordOrder;