Pivot table....building arguments for the .RowField property
I am trying to write a generic Pivot Table build subroutine. To do that, I want to pass it things like the Table name, the Pivot Fields, Row Fields, Column Fields etc. Here's my problem. The current statement is as follows
ActiveSheet.PivotTables(MyTableName).AddFields RowFields:=Array("Status", "Fix-It Owner"
What I want to do, is build a string to pass to this routine, that will contain the value
"Array("Status", "Fix-It Owner") etc. So the first 'quote' in that string needs to not be there, the 'quotes' around Status and Fix-It Owner NEED To be there etc. I can certainly build the string ok and place it in a variable, but when I USE that variable after the RowFields:= I just get an error. Any ideas
Here's how I want it to loo
RowFields:=MyRowFields .... where MyRowFields is a string I build based on the user inpu
Steve
|