title: vba select slicer item excel
body: <p>I've recently discovered VBA code to filter slicers based off of variable names. It is a great tool for filtering what you want to see</p>
  
  <p>The next step in my code is to potentially REMOVE visible data from my pivot table/chart (automatically). </p>
  
  <p>Lets say I already have a variable "Remove_ITEM" that needs to be removed from the data shown. Remove_item is inside slicer ("slicer_Order"). </p>
  
  <p>The data is also inside a data model.</p>
  
  <p>The code below is to ONLY show REmove_Item:</p>
  
  <pre><code>ActiveWorkbook.SlicerCaches("Slicer_Order").'VisibleSlicerItemsList = ("[Actuals_Table].[Order].&amp;["&amp; Remove_item &amp;"]")
  </code></pre>
  
  <p>Now i want to do the opposite</p>