Adding RadPivotFieldList to your project

In this article we will show how to integrate RadPivotFieldList with RadPivotGrid. We will extend our project from the Getting Started article for RadPivotGrid.

Adding RadPivotFieldList

RadPivotFieldList can be used after adding reference to the following assemblies:

  • Telerik.Windows.Controls
  • Telerik.Windows.Controls.PivotFieldList
  • Telerik.Windows.Controls.Navigation
  • Telerik.Windows.Controls.Input
  • Telerik.Windows.Controls.Data
  • Telerik.Windows.Controls.Pivot
  • Telerik.Pivot.Core

You can add your RadPivotFieldList directly in the XAML. First step is to define pivot namespace: xmlns:pivot="http://schemas.telerik.com/2008/xaml/presentation/pivot". After that add the code below:

<pivot:RadPivotFieldList Name="radPivotFieldList1" Grid.Column="1" /> 

Now the only thing you have to set is the DataProvider:

<pivot:RadPivotFieldList Name="radPivotFieldList1" Grid.Column="1"  DataProvider="{StaticResource LocalDataProvider}"/> 

Here's the result of the modified application from Getting Started article:
Rad Pivot Grid Rad Field List Getting Started 01

Now by using RadPivotFieldList you are able to modify RadPivotGrid at runtime and to generate reports with entire new structure and information. For example:
Rad Pivot Grid Rad Field List Getting Started 02

The OlapDataProviders (AdomdDataProvider and XmlaDataProvider) have a default distinct values limit of 1000 records. This is why if you have more distinct values in your database you won't see them all in the pivot field list control. To alter this number, set the DistinctValuesLimit property of the provider.

See Also

In this article
Not finding the help you need? Improve this article