+ Reply to Thread
Results 1 to 5 of 5

Copy data from multiple files into one file

  1. #1
    Forum Contributor tax112's Avatar
    Join Date
    02-28-2013
    Location
    Thailand
    MS-Off Ver
    Excel 2016 | 2019
    Posts
    438

    Copy data from multiple files into one file

    Hi everybody
    I have many files
    111-a1.xls, 111-a2.xls, ..111-an.xls
    112-a1.xls, 112-a2.xls, ..112-an.xls
    ....
    333-a1.xls, 333-a2.xls, ..333-an.xls
    All these files are contained in a folder, each file has only 1 sheet.
    The data per file starts at A1. Now I want to copy the files into a file. Specifically:
    Copy the files 111-a1.xls, 111-a2.xls, ..111-an.xls to one 111.xlsx file.
    Copy files 112-a1.xls, 112-a2.xls, ..112-an.xls to a file 112.xlsx
    -----
    Copy the files 333-a1.xls, 333-a2.xls, ..333-an.xls to one 333.xlsx file.
    Someone can help me.
    Best regards.

  2. #2
    Forum Contributor tax112's Avatar
    Join Date
    02-28-2013
    Location
    Thailand
    MS-Off Ver
    Excel 2016 | 2019
    Posts
    438

    Re: Copy data from multiple files into one file

    Who can please help me?

  3. #3
    Valued Forum Contributor
    Join Date
    05-15-2017
    Location
    US
    MS-Off Ver
    365
    Posts
    896

    Re: Copy data from multiple files into one file

    What code do you already have?
    Can you provide anything you have already tried or trying?

    You will need to have some looping logic to handle how each file will be processed.. in this case you need to look at each file name to determine which file to paste/ move the data into.

  4. #4
    Forum Expert
    Join Date
    05-29-2020
    Location
    NH USA
    MS-Off Ver
    365
    Posts
    2,103

    Re: Copy data from multiple files into one file

    Give this a try. I recommend you create a test folder with a few files. This code will not add sheets to an existing parent file.

    Please Login or Register  to view this content.

  5. #5
    Forum Contributor tax112's Avatar
    Join Date
    02-28-2013
    Location
    Thailand
    MS-Off Ver
    Excel 2016 | 2019
    Posts
    438

    Re: Copy data from multiple files into one file

    Thank you.
    I will try.

+ 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] macro to copy/paste multiple files with changing data to main XLSM file
    By conjohn562 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-13-2021, 05:48 PM
  2. [SOLVED] Copy specific data from multiple files to one file
    By leebird in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 09-27-2016, 11:58 AM
  3. [SOLVED] HELP: Copy Data from Multiple CSV files to an output xls file
    By Anatawan in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-31-2014, 12:33 AM
  4. [SOLVED] How to Extract Data from Multiple Files in Same Folder and Copy Data to One File
    By champ052005 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-10-2013, 01:25 PM
  5. [SOLVED] Need a macro to copy paste data from multiple files into a file as a database
    By etandogan in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 12-13-2012, 02:14 AM
  6. Open a file and copy data into multiple files
    By ncduke in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-12-2010, 09:39 AM
  7. How do I pull data from multiple files and copy into one file
    By JT in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-03-2005, 03:06 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