You might encounter an issue with Do Events if you are using event triggers in your form.
For instance, any keys pressed while a function is running will be sent by Do Events The keyboard input will be processed before the screen is updated, so if you are changing cells on a spreadsheet by holding down one of the arrow keys on the keyboard, then the cell change event will keep firing before the main function finishes.
Display Status Bar = True ''//Make sure that the statusbar is visible For i = 1 To i Max ''// imax is usually 30 or so fraction Done = CDbl(i) / CDbl(i Max) Application.
Orientation = xl Column Field Then Dim i As Long On Error Resume Next ' Needed to avoid getting errors when manipulating fields that were deleted from the data source.
Screen Updating = True End Sub Sub Filter Pivot Table() Application.
Sub Creating Pivot Table New Data() 'Creating pivot table Dim Pvt Tbl As Pivot Table Dim ws Data As Worksheet Dim rng Data As Range Dim Pvt Tbl Cache As Pivot Cache Dim ws Pvt Tbl As Worksheet Dim pvt Fld As Pivot Field 'determine the worksheet which contains the source data Set ws Data = Worksheets("Raw_Data") 'determine the worksheet where the new Pivot Table will be created Set ws Pvt Tbl = Worksheets("3N3E") 'delete all existing Pivot Tables in the worksheet 'in the Table Range1 property, page fields are excluded; to select the entire Pivot Table report, including the page fields, use the Table Range2 property. Pivot Tables If Msg Box("Delete existing Pivot Table!
Hope this helps others...i found it very difficult to find code that did this the "proper way" rather than using code similar to the macro recorder. Clear End If Next Pvt Tbl 'A Pivot Cache represents the memory cache for a Pivot Table report. Create a new Pivot Table cache, and then create a new Pivot Table report based on the cache.
Same for the IVUDDCIndicator (its a column in my data but in the row label of the pivot table).