Pivot Table VBA

H

HELP

with ActiveSheet.PivotTables("PivotTable").PivotFields("sls_no")
.Orientation = xlRowField
.Position = 1

I am trying to figure out what code should be used to drag from the field
list into the pivot table. The code above does not work. Does anyone know the
correct code?

Thank you.
 
D

Debra Dalgleish

You could turn on the macro recorder as you manually drag the field into
the pivot table. Then, use the code that was created.
 
Top