+ Reply to Thread
Results 1 to 3 of 3

Creating a PivotTable in VBA Failing

  1. #1
    Registered User
    Join Date
    07-04-2012
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    54

    Creating a PivotTable in VBA Failing

    Hi there, I'm having a little bit of trouble creating a pivot table using VBA, and not sure why, given that I'm doing it as part of a function that's working fine on a different project and being called in exactly the same way?

    The macro fails on the
    Please Login or Register  to view this content.
    step
    with the error message: Method 'Add' of object 'PivotCaches' failed. I get a similar message if I try pivotcaches.create.
    any help would be much appreciated.
    here's the function:
    Please Login or Register  to view this content.
    Last edited by Cutter; 08-03-2012 at 10:21 AM. Reason: Removed OP request to delete duplicate thread

  2. #2
    Valued Forum Contributor
    Join Date
    03-23-2012
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    1,093

    Re: Creating a PivotTable in VBA Failing

    Try changing the following line:

    Please Login or Register  to view this content.
    To:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    07-04-2012
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    54

    Re: Creating a PivotTable in VBA Failing

    Tried that, same error message only with ".create" instead of ".add" :/

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Bookmarks

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