ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   drill down again (https://www.excelbanter.com/excel-discussion-misc-queries/127449-drill-down-again.html)

[email protected]

drill down again
 
is there any solution to iterate through pivotitems and set them
hidden/showed ?
imho it seems VERY stupid to have to write code like this to show one
item, instead
of hiding all and showing what you need, you are provided with ONLY the
inverse method :(


ActiveSheet.PivotTables("PivotTable1").PivotFields ("[a].[b]").HiddenItemsList
= all_but_what_i_need :(


Roger Govier

drill down again
 
Hi

Clicking the Show All box is a toggle. If it is ticked it shows
everything, untick it and everything is hidden, then allowing any
individual item to be selected.

--
Regards

Roger Govier


wrote in message
oups.com...
is there any solution to iterate through pivotitems and set them
hidden/showed ?
imho it seems VERY stupid to have to write code like this to show one
item, instead
of hiding all and showing what you need, you are provided with ONLY
the
inverse method :(


ActiveSheet.PivotTables("PivotTable1").PivotFields ("[a].[b]").HiddenItemsList
= all_but_what_i_need :(




Lori

drill down again
 
Try the group command if you have more than a few to do. You may find
it easier to hide other fields first, you can select multiple cells by
holding down ctrl.

Tip: if you want to base the group selection on a list in another
sheet, select a cell outside the pivot table first, choose data
filter advanced filter with the other list as criteria and the pivot
table field as data range. Then group just the visible cells from the
filtered selection by pressing ctrl+;. Click data filter show all
to show all the data again.


On Jan 24, 10:05 am, wrote:
is there any solution to iterate through pivotitems and set them
hidden/showed ?
imho it seems VERY stupid to have to write code like this to show one
item, instead
of hiding all and showing what you need, you are provided with ONLY the
inverse method :(

ActiveSheet.PivotTables("PivotTable1").PivotFields ("[a].[b]").HiddenItemsLi*st
= all_but_what_i_need :(



Debra Dalgleish

drill down again
 
There's no code equivalent to using the Show All checkbox that's
available manually.

wrote:
is there any solution to iterate through pivotitems and set them
hidden/showed ?
imho it seems VERY stupid to have to write code like this to show one
item, instead
of hiding all and showing what you need, you are provided with ONLY the
inverse method :(


ActiveSheet.PivotTables("PivotTable1").PivotFields ("[a].[b]").HiddenItemsList
= all_but_what_i_need :(



--
Debra Dalgleish
Contextures
http://www.contextures.com/tiptech.html



All times are GMT +1. The time now is 06:25 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com