LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 23
Default Macro to Pivot data in each sheet within a workbook

Hi ,
Thanks for the reply, will try out the process and get back.
sidm

ryguy7272 wrote:
Ok, sounds like you are kind of new to VBA. No problem at all, just be aware
of the fact that this will take a bit of work. It's very gratifying when you
figure it out though!! Try recording a macro as you build one Pivot Table.
Here's some info. about macro-recording:

http://www.anthony-vba.kefra.com/vba/vbabasic1.htm

Look at your code. Compare your code to my code, below:

Sheets("MergeSheet").Select

Cells.Select
ActiveWorkbook.PivotCaches.Add(SourceType:=xlDatab ase, SourceData:= _
Sheets("MergeSheet").Range("A1").CurrentRegion).Cr eatePivotTable _
TableDestination:="", TableName:="PivotTable1", _
DefaultVersion:=xlPivotTableVersion10

ActiveSheet.PivotTableWizard TableDestination:=ActiveSheet.Cells(3, 1)
ActiveSheet.Cells(3, 1).Select

Notice, my sheet is named 'MergeSheet'

Pay attention to this part:
.Range("A1").CurrentRegion)

You'll need a For...Next loop too. See a sample he
http://www.mrexcel.com/archive/VBA/24967.html

Post back with specific questions.

Hi ,
What code would I need to create an individual Pivot for data in each sheet

[quoted text clipped - 6 lines]
Thanks,
sidm


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/201004/1

 
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
Macro to copy specific data from master workbook to another workbook Mark767 Excel Programming 12 September 1st 09 08:57 PM
Help needed: Getting all sheet setup data from one workbook toanother workbook Lostguy Excel Programming 1 July 8th 08 02:43 PM
Aquiring data from one sheet to another sheet in the same workbook No News Excel Worksheet Functions 10 August 1st 06 08:01 AM
Help to sort out filtered data from the data contained in another sheet of the same workbook No News Excel Worksheet Functions 1 July 28th 06 04:04 PM
Copying data from workbook/sheets to another workbook/sheet yukon_phil Excel Programming 0 July 26th 06 07:33 PM


All times are GMT +1. The time now is 02:09 PM.

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

About Us

"It's about Microsoft Excel"