Results 1 to 19 of 19

Thread: [RESOLVED] Showdetail of Pivot table values based on criteria

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2009
    Posts
    295

    Resolved [RESOLVED] Showdetail of Pivot table values based on criteria

    I want to show detail of the values based on criteria appearing in my pivot table in a separate worksheets. Below is what I have so far, which shows the details for all items.

    Code:
    Sub MakeReports()
        Dim c As Range
        With ActiveSheet.PivotTables(1)
            For Each c In .DataBodyRange.Resize(, 1)
               c.ShowDetail = True
            Next c
        End With
    End Sub
    below is pivot snapshot, I want macro to refer to the last 2 columns (.i.e. Column D and E) and if the values in both columns match then macro should show the details of both the values in one worksheet (or in separate worksheet is also fine) and where it doesn't match it should not show details and loop through the cells of both the columns till the pivot end. Excel version used by me is excel 2010.
    Attached Images Attached Images  
    Last edited by abhay_547; Mar 1st, 2018 at 12:31 AM.

Tags for this Thread

Posting Permissions

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



Click Here to Expand Forum to Full Width