PDA

View Full Version : [SOLVED] Updating PT Slicers is Causing Macro to Fail



Jim Clayton
08-10-2018, 08:18 AM
**WARNING**CROSS-POST** https://www.excelforum.com/excel-programming-vba-macros/1241215-changing-names-of-slicers-is-prompting-an-error.html
There. I've told on myself. I'm not getting a huge response on the other forum so I thought I'd try my hand here. I'm getting an error (end/debug) message thrown when I change names of the slicers. After changing the names, the Macro no longer works...or rather it works, but with an End/Debug message. When you view the code, the below line is highlighted.
If Not ActiveWorkbook.SlicerCaches(SlicerName).SlicerItems.Item(1).Value = "N/A" Then
Rating was changed to Class/Rating. Class changed to Approvals. Requirements changed to Special Req. I changed it on the Data sheet. Then I changed the slicer name. Then I changed the macro. Basically update one, update the rest. So, I'm trying to figure out what I need to do to make it start working again. If I change the slicer names back, it works fine, but I kinda need to make these changes. So, that's where I'm at with it. I also tried refreshing the PT and inserting new Slicers. Still not working. I’m not sure where I’m going wrong. Would greatly appreciate if someone could take a look at it for me and provide some insight. Tks.

Jim Clayton
08-10-2018, 01:05 PM
Solved