Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Pivot Tables

Hi,

I have recorded the macro below that creates a Pivot Table. What I would
like to do is add additional sheets to the Array below by using a macro. It
would be great if I could type in an additional sheet names by using an Input
Box. Since this is for payroll, I will probably have over 52 sheets by the
end of the year.

Range("A13").Select
ActiveSheet.PivotTableWizard SourceType:=xlConsolidation,
SourceData:=Array _
("'01062005'!R11C2:R500C21", "'01132005'!R11C2:R500C21", _
"'03032005'!R11C2:R500C21", "'05052005'!R11C2:R500C21")
ActiveSheet.PivotTables("PivotTable5").SmallGrid = False
ActiveSheet.PivotTables("PivotTable5").AddFields RowFields:="Row", _
ColumnFields:="Column"
Application.CommandBars("PivotTable").Visible = False
Range("A1").Select
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
Building pivot tables in Excel 2007 based on existing pivot tables? [email protected] Excel Discussion (Misc queries) 4 December 26th 07 08:05 PM
Pivot Table Data Adding contents of two pivot tables and param que Roundy Excel Discussion (Misc queries) 0 July 2nd 07 10:20 PM
Average Calculations from Pivot Tables - Get Pivot Data? Calc Fiel westy Excel Worksheet Functions 5 March 10th 07 01:31 AM
How does the term 'pivot' apply to Excel's Pivot tables and Pivot. stvermont Excel Discussion (Misc queries) 1 February 17th 05 01:34 AM
Pivot tables-controlling user interaction with pivot tables Sindhura Excel Programming 0 August 27th 03 02:10 PM


All times are GMT +1. The time now is 09:16 AM.

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"