+ Reply to Thread
Results 1 to 2 of 2

VBA that dynamically updates PivotCache, PivotTables, from external workbook

  1. #1
    Registered User
    Join Date
    06-25-2012
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    1

    VBA that dynamically updates PivotCache, PivotTables, from external workbook

    Hello All,

    First, I must admit defeat. While it may be temporary I was hoping that this forum could possible point me in the right direction.

    I currently am working with two files.

    The first file is a template that acts as a pseudo BI tool.

    The second file is a data source that drives the information of the template.

    I have created a Macro that makes the opens both files writes their filepaths to the "Intro" worksheet.
    The second worksheet then activates and creates a dynamic range to be used in the PivotCache which hopefully will drive the PivotTables. Every PivotTable runs from the same PivotCache.

    The issue I am having is twofold.

    First it appears that the PivotCache is not being created so there are most definitely flaws in my coding. Second the code runs but it returns either an Error 13 Type Mismatch or when I change the ptRange to ptRange.Address it gives me this long convoluted string that essentially says I don't have my data set up correctly. (Run-Time error -2147024809 (80070057)

    I have included my code for any insight. Thank you very much.


    Please Login or Register  to view this content.
    Please Login or Register  to view this content.
    Last edited by alansidman; 11-21-2013 at 08:47 PM. Reason: code tags added

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,741

    Re: VBA that dynamically updates PivotCache, PivotTables, from external workbook

    Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code.

    Posting code between [CODE]Please [url=https://www.excelforum.com/login.php]Login or Register [/url] to view this content.[/CODE] tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

    Highlight your code and click the # icon at the top of your post window. More information about these and other tags can be found here



    (I have added them for you this time. Please read our rules and comply with them in the future.)
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How can I Dynamically link to an External Workbook?
    By Sandcastle in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-04-2013, 04:59 PM
  2. Need a macro that updates external links every 5 minutes
    By mk3ll00 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-05-2013, 01:34 PM
  3. Auto Updates to external spreadsheets
    By cdotyii in forum Excel General
    Replies: 4
    Last Post: 06-11-2012, 04:23 PM
  4. problem with multiple PivotTables on a PivotCache
    By rick.hunter.007 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-14-2008, 05:18 PM
  5. [SOLVED] Sending pivottables to external users
    By RMF in forum Excel General
    Replies: 5
    Last Post: 03-29-2006, 06:59 PM

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