+ Reply to Thread
Results 1 to 4 of 4

Enable Auto Refresh - Wait for refresh to sinish before running a macro

  1. #1
    Forum Contributor
    Join Date
    07-21-2009
    Location
    Sheffield, England
    MS-Off Ver
    Excel 2010
    Posts
    117

    Enable Auto Refresh - Wait for refresh to sinish before running a macro

    I have an excel workbook which has several sheets that each import external data on file open. These data sources are already defined in the workbook and do not use VBA to import the data.

    I would like to run some VBA code after the external data has been refreshed but I do not know how to. Can anyone help?

  2. #2
    Forum Expert Colin Legg's Avatar
    Join Date
    03-30-2008
    Location
    UK
    MS-Off Ver
    365
    Posts
    1,252

    Re: Enable Auto Refresh - Wait for refresh to sinish before running a macro

    Hi,

    Is the data being pulled into a query table or a pivot table?
    Last edited by Colin Legg; 02-21-2011 at 08:22 AM.
    Hope that helps,

    Colin

    RAD Excel Blog

  3. #3
    Forum Contributor
    Join Date
    07-21-2009
    Location
    Sheffield, England
    MS-Off Ver
    Excel 2010
    Posts
    117

    Re: Enable Auto Refresh - Wait for refresh to sinish before running a macro

    Hi Colin, it is a Query Table.

    I have used 'Data > Import External Data > Import Data' to get information from another workbook.

  4. #4
    Forum Expert Colin Legg's Avatar
    Join Date
    03-30-2008
    Location
    UK
    MS-Off Ver
    365
    Posts
    1,252

    Re: Enable Auto Refresh - Wait for refresh to sinish before running a macro

    Hi Tom,

    Query tables have an AfterRefresh() event handler which you can use to call your macro. Here's a primer to get you started but if it doesn't make sense to you then you're welcome to attach a sample workbook and I (or someone else) will be happy to add the relevant code for you.

+ 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