+ Reply to Thread
Results 1 to 2 of 2

Excel 2007 : Macro to add Pivot table Data fields

  1. #1
    Registered User
    Join Date
    MS-Off Ver
    Excel 2007

    Macro to add Pivot table Data fields


    I have data on sheet4 which has 13 columns in total 1st being the heading. Now i want to create a pivot table on sheet5. Problem is that the no. of rows change and also the number of columns. Sometimes the columns will be 12, or 6 or 8. I have a macro to dim the selection range and then it creates the pivot table on sheet 5 but does not add heading to row label and rest of the columns to datafield as i dont know the code to specify for changing columns.

    Please Help.!!

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    Essex, UK
    MS-Off Ver

    Re: Macro to add Pivot table Data fields

    It's not really clear to me what you're overall workflow is here - ie are you constantly adding a new Pivot or is it your intention to use a single dynamic range as the source for the Pivot ?

    In terms of automating the addition of fields to the PT, in basic terms:

    Please Login or Register  to view this content.
    adjust as necessary... in terms of determining the data source that should be straightforward enough I think ?

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1