+ Reply to Thread
Results 1 to 1 of 1

VBA to Open, Copy & Paste across multiple files

  1. #1
    Registered User
    Join Date
    09-19-2016
    Location
    USA
    MS-Off Ver
    2016
    Posts
    1

    Post VBA to Open, Copy & Paste across multiple files

    Hi,

    I am attempting to build out a master workbook that will streamline some work processes for us, however I'm running into a bit of a wall.

    This workbook so far has three macros, however if it is better I can consolidate them into one.

    The first macro pulls in all excel files in a folder. For example, if there are 4 files in the folder, then excel will populate cells A2:A5 with the file names. I have this written out and it works.

    The second macro's goal is to copy and paste data from each files "summary" page, and paste it in to the "master". I have the copy and paste portion of this working, however ideally it would run through all the files that the first macro pulls into column A. I am unable to figure out how to get this to loop.

    The third macro is by far the longest, though I'll do my best to summarize. It opens up the first file in column A, the file will have 12 tabs that I need to filter, copy and then paste into a new workbook that is specific to that tab only. The newly created workbook needs to be saved with the date. Once this is complete, it moves on to the next tab in the spread sheet and does the same process. My first problem is that I am not able to figure out how to loop it through all files in Column A. Once it is done with the first file in column A, it should go through the same process with the second file. However, tab 1 in file 2 needs to be pasted in below the data pasted in from tab 1 file 1... if that makes sense.

    I've pasted in each macro below, I am a beginner at all of this, so I am sure there are ways to consolidate it.

    Macro 1:

    Please Login or Register  to view this content.
    Macro 2: (note - the workbook it is opening is just the file location of the first file in column A. I only did this so I could work on the rest of the code).

    Please Login or Register  to view this content.
    Macro 3: (note - the workbook it is opening is just the file location of the first file in column A. I only did this so I could work on the rest of the code).

    Please Login or Register  to view this content.
    Last edited by JBeaucaire; 09-20-2016 at 06:07 PM. Reason: Added missing CODE tags. Please read and follow the Forum Rules, link above in the menu bar. Thanks.

+ 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. [SOLVED] Copy and paste data from multiple files into open workbook
    By 1953CAG in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-04-2016, 05:27 AM
  2. Open multiple files based on cell value then copy and paste
    By Ctomo in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-14-2016, 10:06 AM
  3. Open Multiple Files, Copy Worksheet, Paste in to Specific Tab in Original Workbook
    By freybe06 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-30-2013, 10:27 AM
  4. Replies: 0
    Last Post: 04-13-2013, 10:45 AM
  5. Open/close files and copy and paste problem
    By kb9nvh in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-12-2011, 03:30 PM
  6. Macro - open files, copy & paste values
    By aron.silan in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-17-2010, 09:24 AM

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