Ok, I am new to VBA, but I know that this should be possible. I spent some time coding Android applications, but I would not call myself almost an expert, perhaps not even intermediate, to be honest. However, alas, excel does not use java. Here is my problem:
All you need to do is 6 other pivot tables on one sheet to simulate what I will call the main pivot table. The only feature that it should simulate, although (at the moment, I suppose), is when the primary expands / collapses, the rest should follow suit.
I assume that the code will look like onclicklistener in java, and when the code “hears” a click for crash or extension in the main pivot table, it just applies the same crash or extension to the other six. The remaining 6 anchor points will always have the same row labels , therefore, the error in transferring the “location” of the click from the main to the rest should never be a problem.
I tried to write the extension of one of the row labels in the pivot table and got this code.
ActiveSheet.PivotTables("PivotTable1").PivotFields("Year").PivotItems("2005"). _ ShowDetail = True
I know, however, that this is the encoding to execute this extension (and ShowDetail = False will crash it). I think that I need, as I said, the listener to “hear” a click of some extension / break of the primary pivot table, a way to store / transfer information about which label label was clicked (“location”, click if you do it) and then the general version of the above code to execute on another 6, I assume that sorting is used for the loop.
Am I on the right track to help guys? Thanks a ton, as always.