+ Reply to Thread
Results 1 to 8 of 8

combine 1st sheet from all workbooks in folder

  1. #1
    Registered User
    Join Date
    06-10-2013
    Location
    boston
    MS-Off Ver
    Excel 2010
    Posts
    79

    combine 1st sheet from all workbooks in folder

    Here is the issue and I am not sure if it is even possible but I figured I would give it a try.

    I have a folder with 24 generated workbooks. Each workbook has the same number of worksheets and the same format.

    In each workbook the first sheet is what I need and each first sheet is named "CHART"

    I need a Macro that will take all workbooks in this folder, we can call the folder C:\combine, and copy the first sheet of each workbook into a combined workbook of 24 worksheets. The sheet names do not matter because I have a program that will auto name the tabs based on a list.

    Anybody have a good ideas?

    Thanks

  2. #2
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,942

    Re: combine 1st sheet from all workbooks in folder

    Select the files to combine in the dialog.
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    06-10-2013
    Location
    boston
    MS-Off Ver
    Excel 2010
    Posts
    79

    Re: combine 1st sheet from all workbooks in folder

    Ran the program and it came back with "Run time error 1004: Copy Method of Worksheet class failed

    Please Login or Register  to view this content.
    The red line is where the debug brought me

  4. #4
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,942

    Re: combine 1st sheet from all workbooks in folder

    Nothing that I try creates that error (protection, hidden sheets, sharing). Does it fail on a specific workbook, or on the first workbook?

  5. #5
    Registered User
    Join Date
    06-10-2013
    Location
    boston
    MS-Off Ver
    Excel 2010
    Posts
    79

    Re: combine 1st sheet from all workbooks in folder

    First workbook, which has about 9 hidden sheets.

  6. #6
    Registered User
    Join Date
    06-10-2013
    Location
    boston
    MS-Off Ver
    Excel 2010
    Posts
    79

    Re: combine 1st sheet from all workbooks in folder

    I also just tried it will 4 test workbooks and the same thing happened

  7. #7
    Forum Expert
    Join Date
    02-11-2014
    Location
    New York
    MS-Off Ver
    Excel 365 (Windows)
    Posts
    5,942

    Re: combine 1st sheet from all workbooks in folder

    Can you post an example workbook that is giving the error? Cleaned up, if there is sensitive information.

  8. #8
    Registered User
    Join Date
    06-10-2013
    Location
    boston
    MS-Off Ver
    Excel 2010
    Posts
    79

    Re: combine 1st sheet from all workbooks in folder

    Fixed it, it was because i was saving it under Personal.xls.

+ 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. Combine workbooks into an existing workbook in the same folder
    By uberathlete in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-04-2014, 01:51 PM
  2. [SOLVED] combine multi workbooks into one master workbook but I want to combine only sheet 3
    By Goodstart14 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 12-31-2013, 12:22 AM
  3. Need Code to Combine All Workbooks in Folder
    By jcranst in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-01-2012, 02:18 PM
  4. Combine (3) Workbooks to Master Sheet
    By ssteines in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-21-2011, 04:00 PM
  5. combine workbooks stored in the same folder into 1 a summary sheet.
    By lrm75uk in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-22-2010, 04:09 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