Help / WLanguage / WLanguage functions / Controls, pages and windows / Pivot Table functions
  • Implementation
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
<Pivot table>.Filter (Function)
In french: <Tableau croisé dynamique>.Filtre
Enables or disables a filter on a Pivot Table control.
Caution: Only a filter defined in the "Content" tab of the description window of Pivot Table control can be used. When <Pivot table>.Filter is used, only the display of the Pivot Table control is modified, the different totals are not updated.
// -- Selecting a row of COMBO_Filter_by_family
// Filters the Pivot Table control on the family of products that must be taken into account
PVT_Statistics.Filter(COL_Caption, MySelf)
IF PVT_Statistics.Count = 0 THEN
STC_NO_DATA.Visible = True
STC_NO_DATA.Visible = False
<Pivot Table control>.Filter(<Display filter> , <Value>)
<Pivot Table control>: Control name
Name of the Pivot Table control to be used.
<Display filter>: Character string
Name of display filter to use. This filter was defined in the "Content" tab of the description window of Pivot Table control.
<Value>: Type corresponding to the filter
  • Value of filter to implement.
  • Empty string ("") to delete the filter.


To implement a filter in a Pivot Table control, you must::
  1. Create the Pivot Table control.
  2. In the description window of Pivot Table control, in the "Content" tab, add one or more display filters.
  3. Create a control allowing the user to select the value of filter. The selection of value will run <Pivot table>.Filter.
A Pivot Table control is defined to display sales statistics:
Pivot table for sales statistics
A filter is defined on the caption of family of products. Filtering by family allows you to only take into account the family specified in the calculation of turnovers.
Definition of filter
The window proposes a combo box allowing the user to choose the family of products to filter:
Choosing the family of products
Related Examples:
WD PivotTable Training (WINDEV): WD PivotTable
[ + ] This example presents the use of the Pivot Table control.

This Pivot Table control is used to display dynamic statistics while grouping the data.
These statistics are calculated form the database.
Component: wd290obj.dll
Minimum version required
  • Version 23
This page is also available for…
Click [Add] to post a comment

Last update: 06/26/2023

Send a report | Local help