Hello All,
I have tried to search on the site looking for a way to use a record macro on any sheet within a workbook. I currently select the slicers and it will work on the original sheet created, but not one the active sheet.
Sub Yonick()
With ActiveWorkbook.SlicerCaches("Slicer_GSM")
.SlicerItems("Yonick").Selected = True
.SlicerItems("Hourihan").Selected = False
.SlicerItems("Kiely").Selected = False
.SlicerItems("Cregin").Selected = False
.SlicerItems("Romero").Selected = False
.SlicerItems("Munson").Selected = False
.SlicerItems("MBD").Selected = False
End With
End Sub
I have tried changing activeworkbook to activesheet. Also, added "activesheet." after activeworkbook. I tried to follow someone who was using DIM wsheets code.
Thank you in advacne.
I have tried to search on the site looking for a way to use a record macro on any sheet within a workbook. I currently select the slicers and it will work on the original sheet created, but not one the active sheet.
Sub Yonick()
With ActiveWorkbook.SlicerCaches("Slicer_GSM")
.SlicerItems("Yonick").Selected = True
.SlicerItems("Hourihan").Selected = False
.SlicerItems("Kiely").Selected = False
.SlicerItems("Cregin").Selected = False
.SlicerItems("Romero").Selected = False
.SlicerItems("Munson").Selected = False
.SlicerItems("MBD").Selected = False
End With
End Sub
I have tried changing activeworkbook to activesheet. Also, added "activesheet." after activeworkbook. I tried to follow someone who was using DIM wsheets code.
Thank you in advacne.