Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 30
Default Pivot Table Macro in Excel 2002

I'm trying to create a macro that will create a Pivot
Table. I'm using the "record" function to record my
steps as I create the Pivot Table.
When I try to run the macro, I get an error: Run-time
error '1004':
AddFields method of PivotTable class failed.

Here's the line in the macro code that fails:
ActiveSheet.PivotTables("PivotTable1").AddFields
RowFields:=Array( _
"Brand Code", "Iams Item Code", "Description"),
ColumnFields:="Date"


Any ideas on what I'm doing wrong?

Thanks,
Scott
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2002: Can I sort columns of the Pivot Table ? Mr. Low Excel Discussion (Misc queries) 2 October 6th 07 12:41 AM
Excel 2002 - Pivot Table : Can I divide instead of sum ? Mr. Low Excel Discussion (Misc queries) 2 December 7th 06 12:54 PM
Excel 2002 Pivot Table Date ~Dave~ Excel Worksheet Functions 1 July 28th 05 07:08 PM
Excel 2002 Pivot Table Protection Kirk P. Excel Discussion (Misc queries) 1 February 23rd 05 10:08 PM
Pivot Table in Excel 2002 Kirk P. Excel Discussion (Misc queries) 2 February 21st 05 07:37 PM


All times are GMT +1. The time now is 08:38 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"