I was able to get my pivot table running using the following code:


Sub reportpivot()

ActiveSheet.Name = "Report"
    
Dim WSD As Worksheet
Dim PTCache As PivotCache
Dim pt As pivottable
Dim PRange As Range
Dim FinalRow As Long
Dim FinalCol As Long
Set WSD = Worksheets("Report")

'Delete any prior pivot tables
For Each pt In WSD.PivotTables
    pt.TableRange2.Clear
Next pt

'Define input area and set up a Pivot Cache
FinalRow = WSD.Cells(Application.Rows.Count, 1).End(xlUp).Row
FinalCol = WSD.Cells(16, Application.Columns.Count).End(xlToLeft).Column
Set PRange = WSD.Cells(16, 1).Resize(FinalRow - 15, FinalCol)
Set PTCache = ActiveWorkbook.PivotCaches.Add(SourceType:=xlDatabase, _
    SourceData:=PRange.Address)

Set pt = PTCache.CreatePivotTable(TableDestination:=WSD.Cells(2, _
    FinalCol + 2), TableName:="PivotTable1")

'Disables Pivot Table update until the end to speed up calculation
pt.ManualUpdate = True

'Set up the row and column fields
pt.AddFields RowFields:="Account Category"

'Set up the data fields
With pt.PivotFields("Balances FC")
    .Orientation = xlDataField
    .Function = xlSum
    .Position = 1
    .NumberFormat = "#,##0"
    .Name = "BalancesFC"
End With

With pt.PivotFields("Balances USD")
    .Orientation = xlDataField
    .Function = xlSum
    .Position = 1
    .NumberFormat = "#,##0"
    .Name = "BalancesUSD"
End With

With pt.PivotFields("Data")
    .Orientation = xlColumnField
    .Position = 1
End With

'Calculate the pivot table
pt.ManualUpdate = False
pt.ManualUpdate = True

'Format the pivot table
pt.ShowTableStyleRowStripes = True
pt.TableStyle2 = "PivotStyleMedium10"

End Sub
Normally, after the pivot table is created and the fields are set, the table displays all the data in the two columns.

The problem is that when the pivot table generates, it comes up filtered as "Select All", with every box checked, but shows nothing. To make the data appear, all I need to do is click the filter and click OK (all the boxes remain checked from before) to show the data. I want it to just auto-show everything without me having to manually do it. I recorded a macro for it but it comes up blank, which is weird considering it normally shows filter categories.

I browsed around and found code to essentially just "Select All." However, it takes about a minute to run each time, which is a waste of time and inefficient since I need to run it hundreds of times.

Sub Pivot_ShowAll()

    Dim pt As PivotTable, pf As PivotField, pi As PivotItem
    
    Application.ScreenUpdating = False
    
    For Each pt In ActiveSheet.PivotTables
        pt.ManualUpdate = True
        For Each pf In pt.PivotFields
            For Each pi In pf.PivotItems
                pi.Visible = True
            Next pi
        Next pf
        pt.ManualUpdate = False
    Next pt
    
    Application.ScreenUpdating = True
    
End Sub
Any help would be appreciated.