Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Property Grid
  [Collapse]Pivot Grid
   [Expand]Getting Started
   [Collapse]Fundamentals
     Pivot Grid Fields
     Information Presentation Basics
     Hierarchical Value Presentation
     Product Class Structure
     Main Features
   [Expand]Binding to Data
   [Expand]Data Shaping
   [Expand]Data Analysis
   [Expand]Layout
   [Expand]Focus and Navigation
   [Expand]Printing and Exporting
   [Expand]Appearance
   [Expand]Design-time Features
   [Expand]Miscellaneous
   [Expand]UI Elements
   [Expand]End-User Capabilities
   [Expand]Examples
   [Expand]Member Tables
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Pivot Grid Fields

Pivot Grid Fields supply data to PivotGridControl. Fields are visualized with field headers which you can drag-and-drop between the Pivot Grid areas. Dragging fields between areas modifies the report layout.

Expanded Creating

To create a report in PivotGridControl, create Pivot Grid fields and position them in the header areas. To perform these actions in code, follow the steps below:

  1. create a PivotGridField object and add it to the PivotGridControl.Fields collection;
  2. specify the field's area and position within this area using the PivotGridFieldBase.Area and PivotGridFieldBase.AreaIndex properties (note that the PivotGridFieldBase.AreaIndex property can be set only after the field is added to the control's field collection).

Expanded Positioning

A field can be positioned within one of four areas: Column, Row, Data, and Filter Header Area. The field's function is determined by an area in which it is located:

  • position a field within the Column Header Area to list its values along the control's top edge. Field's values will be column headers;
  • position a field within Row Header Area to list its values along the control's left edge. Field's values will be row headers;
  • position a field within Data Header Area to calculate summaries against the fields. The summaries will be calculated for all the cells, each cell is identified by a column and a row;
  • position a field within the Filter Header Area to make this field available for subsequent actions. End-users can drag the field to another area or filter a field using the Filter Dropdown.

To learn more, see the Field Layout section.

Expanded Binding

Pivot Grid supports bound and unbound fields. A bound field retrieves data from a Pivot Grid data source. An unbound field is not associated with a data source and should be populated with data manually. To learn more on unbound fields, see Unbound Fields.

To bind a Pivot Grid field to a data source field, set the PivotGridFieldBase.FieldName property to the name of the data source field. Note that the PivotGridFieldBase.UnboundType property is set to UnboundColumnType.Bound (default value). Otherwise, the field is unbound and the PivotGridFieldBase.UnboundType property specifies the field's data type.

To learn more, see the Binding to Data section.

Expanded Filtering

Pivot Grid can display only specific records by applying filter criteria to certain fields.

To learn more, see the Filtering section.

Expanded Field Data

Use the following methods to obtain field data:

Method Description
PivotGridFieldBase.GetUniqueValues Obtains an array of distinct field values from the underlying data source. This method is used to fill in field's Filter Editors.
PivotGridFieldBase.GetAvailableValues Obtains an array of distinct field values contained in the records which are left after applying filters to other fields.
PivotGridFieldBase.GetVisibleValues Obtains a collection of unique field values contained in the records displayed in the Pivot Grid. Thus, these records are left after applying a field's filter to the field's available values (values contained in the records which are left after applying filters to other fields).

Expanded Example

Expanded See Also

Is this topic helpful?​​​​​​​