ASPxPivotGrid.CustomUnboundFieldData Event
Enables providing data to unbound fields.
Namespace: DevExpress.Web.ASPxPivotGrid
Assembly: DevExpress.Web.ASPxPivotGrid.v24.2.dll
Declaration
Event Data
The CustomUnboundFieldData event's data class is CustomFieldDataEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Field | Gets the field being processed. Inherited from PivotFieldEventArgsBase<T>. |
ListSourceRowIndex | Gets the current row’s index in the data source. |
Value | Sets the cell’s value. |
The event data class exposes the following methods:
Method | Description |
---|---|
GetListSourceColumnValue(Int32, String) | Gets the specified field’s value in the specified row in the control’s underlying data source. |
GetListSourceColumnValue(String) | Gets the specified cell’s value within the current row in the control’s underlying data source. |
Remarks
Note
This member is not supported in Optimized, OLAP, and Server modes. Use ExpressionDataBinding for Optimized mode instead.
The CustomUnboundFieldData event is only fired for unbound fields. To create an unbound field, add a PivotGridField object to the ASPxPivotGrid.Fields collection and set its PivotGridFieldBase.UnboundType property to an appropriate value according to the type of data the field is supposed to display. The field’s PivotGridField.FieldName property must be set to a unique value. This value must not refer to any field in the control’s underlying data source.
The CustomUnboundFieldData event is raised for each row and for each unbound field in the data source. The currently processed row is identified by the CustomFieldDataEventArgs.ListSourceRowIndex property. This property specifies the row’s index in the data source. The processed unbound field is identified by the PivotFieldEventArgsBase<T>.Field property. To provide data for a cell, assign a value to the CustomFieldDataEventArgs.Value property.
For an example on how to use unbound fields, see “Unbound Fields” in the ASPxPivotGrid Demo.
To learn more about unbound fields, see Unbound Data.