ComponentOne FlexPivot for WinForms
Fields Property (C1FlexPivotEngine)
Example 

C1.DataEngine.4 Assembly > C1.FlexPivot Namespace > C1FlexPivotEngine Class : Fields Property
Gets the list of C1FlexPivotField objects exposed by the data source.
Syntax
'Declaration
 
Public ReadOnly Property Fields As C1FlexPivotFieldList
public C1FlexPivotFieldList Fields {get;}
Remarks

This list is created automatically whenever the DataSource property is set.

FlexPivot views are defined by copying fields from this list to the lists that define the view: ValueFields, RowFields, ColumnFields, and FilterFields.

Example
The code below assigns a data source to the FlexPivot engine and then defines a view by adding fields to each of the RowFields, ColumnFields, and ValueFields lists.
// set data source (populates Fields list)
fp.DataSource = GetDataTable();
            
// prevent updates while building FlexPivot view
fp.BeginUpdate();
            
// show countries in rows
fp.RowFields.Add("Country");
            
// show categories and products in columns
fp.ColumnFields.Add("Category");
fp.ColumnFields.Add("Product");
            
// show total sales in cells
fp.ValueFields.Add("Sales");
            
// done defining the view
fp.EndUpdate();
See Also

Reference

C1FlexPivotEngine Class
C1FlexPivotEngine Members