Refresh Pivot Tables

DomoAvocado

New Member
Joined
Nov 15, 2021
Messages
8
Office Version
  1. 365
Platform
  1. Windows
I am trying to create a printable report based on some pivot tables. I was able to get the original header started with header information but I need the program to add new lines for each job underneath each header.

wsJobPiv is the worksheet the Pivot Tables with specific Job Numbers and the Total amount of unique Job Numbers
Cell B1 is the cell used to filter the Job Numbers Pivot Table
Cell AB1 is the same but for total amount of unique Job Numbers

VBA Code:
   'Job Entry
    wsJobPiv.Range("b1").Value = wsPiv.Range("b" & pRow).Value
    wsJobPiv.Range("ab1").Value = wsPiv.Range("b" & pRow).Value
    
    Dim jobCount As Long
    jobCount = wsJobPiv.Range("aa4").Value
    
    For jobcounter = 1 To jobCount
    
        iRow = iRow + 1
        
        'Job Number Entry
        wsPrint.Range("i" & iRow).Value = wsJobPiv.Range("a" & jRow).Value
        
        jRow = jRow + 1
        
    Next jobcounter
    
    wsJobPiv.PivotTables("pvtJobNum").ClearAllFilters
    wsJobPiv.PivotTables("pvtJobCount").ClearAllFilters
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,214,563
Messages
6,120,248
Members
448,952
Latest member
kjurney

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top