Bonjour,
Je souhaiterais filtrer un TCD par rapport au montant. Faire 2 tableau l'un affichant tous les montants positifs, l'autre tous les montant négatifs.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14 With ActiveSheet.PivotTables("Tableaucroisédynamique1").PivotFields("Total dû") ' Filtre selon le champs défini ActiveSheet.PivotTables("Tableaucroisédynamique1").PivotFields("Total dû").ClearAllFilters ' Supprime tous les précédents filtres ActiveSheet.PivotTables("Tableaucroisédynamique1").PivotFields("Total dû").EnableMultiplePageItems = True For Each valeurFiltre In .PivotItems If valeurFiltre < 0 Then valeurFiltre.Visible = False Next For j = 1 To .PivotItems.Count If .PivotItems(j).Value = "0" Or .PivotItems(j).Value = "(Vide)" Then .PivotItems(j).Visible = False ' TCD Filtré sur les cellules à 0.00 End If Next j End With
Partager