PivotGridControl.RetrieveFieldsAsync(FieldArea, Boolean, AsyncCompletedHandler) Method
Creates PivotGridField objects for all fields in a data source, and moves them to the specified area, making them visible or hidden. Performs these actions asynchronously. Allows you to specify custom actions to be performed after this operation is completed.
Namespace: DevExpress.Xpf.PivotGrid
Assembly: DevExpress.Xpf.PivotGrid.v14.2.dll
#Declaration
public void RetrieveFieldsAsync(
FieldArea area,
bool visible,
AsyncCompletedHandler asyncCompleted
)
#Parameters
Name | Type | Description |
---|---|---|
area | Field |
A Field |
visible | Boolean | true to show the created fields; otherwise, false. |
async |
Async |
An Async |
#Remarks
This overload clears the PivotGridControl.Fields collection and populates it with new PivotGridField objects, created for all fields in a data source. The PivotGridField.FieldName property of each field is set to the name of the corresponding data source field. The created fields are moved to the area specified by the area parameter. The visible parameter specifies whether these fields are made visible or hidden.
To learn more about fields, see Creating Fields and Binding Them to Data Fields.
The RetrieveFieldsAsync method is asynchronous. It starts executing the related operation in a background thread, and immediately returns control. The primary UI thread is not blocked, allowing the application to continue responding to end-user actions. For more information about the asynchronous mode, see Asynchronous Mode.
To retrieve fields synchronously, use the PivotGridControl.RetrieveFields method.