Filter pivot table with selected items. Does not work with numbers.

  • Hello everyone,


    I wrote a simple macro with which to filter a pivot table with the items that I have selected.


    When the items in the Pivot Field are not numbers, it works perfectly.
    But when the items are only numbers, it just doesn't work and I don't understand why and how to make it work.


    Any ideas or tips ?
    Thank you in advance!


  • Re: Filter pivot table with selected items. Does not work with numbers.


    I kind of tricked it and now works for any type of value.



    But still, can someone explain what was wrong with the first code?
    I am just curious.