+ Reply to Thread
Results 1 to 2 of 2

How to loop through a filtered pivot table in vba

  1. #1
    Registered User
    Join Date
    12-16-2016
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    1

    How to loop through a filtered pivot table in vba

    I have created a pivot table in vba, and have applied a filter to the data. I need to loop through the rows which match the filter but i am only able to loop through all the data not just the filtered, using .visible is not working.

    'Filter pivot to show sum greater than 100
    ActiveSheet.PivotTables("PivotTable1").PivotFields("AccountID").PivotFilters. _
    Add2 Type:=xlValueIsGreaterThan, DataField:=ActiveSheet.PivotTables( _
    "PivotTable1").PivotFields("Sum of FinancialValue"), Value1:=100

    Any sugegstions
    Thanks
    Echeb

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,926

    Re: How to loop through a filtered pivot table in vba

    You may get a better response if you attach a sample workbook.

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 12-18-2016, 08:37 PM
  2. Check is pivot table filtered
    By zico8 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-13-2016, 02:05 AM
  3. Format pivot table if filtered
    By zico8 in forum Excel General
    Replies: 0
    Last Post: 09-12-2016, 07:54 AM
  4. How to Reduce Filtered Results in Pivot Table?
    By clayjm in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 10-19-2015, 04:42 PM
  5. create a pivot table on a filtered table
    By bzl in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-19-2015, 06:55 AM
  6. Return value from a filtered pivot table
    By Jonathan9 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-28-2013, 06:05 AM
  7. [SOLVED] Loop through rows/columns H and K in filtered table and send emails - Help Please Gurus ;)
    By Alina1404 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-30-2012, 03:23 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1