ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How can I set PivotItem.Visible property to True? (https://www.excelbanter.com/excel-programming/291772-how-can-i-set-pivotitem-visible-property-true.html)

yumi

How can I set PivotItem.Visible property to True?
 
What's wrong with the following codes? I can set visible=false but when I try to set it to true run I receive run time error
at "pi.visible = True"

Dim pi as pivotitem
sheets("pivot").select
For Each pi in ActiveSheet.PivotTables("Pivottable1").PivotFields ("fieldname").PivotItems
If pi.Visible = False Then
pi.Visible = True
End If
Next

yumi

How can I set PivotItem.Visible property to True?
 
(correction!)Please ignore 'run' after 'set it to true'....
Any help would be appreciated!

yumi

How can I set PivotItem.Visible property to True?
 
Problem is solved. Thanks for Debra D.


All times are GMT +1. The time now is 05:26 AM.

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