+ Reply to Thread
Results 1 to 4 of 4

Grabbing worksheets from various workbooks

  1. #1
    Registered User
    Join Date
    07-22-2010
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    85

    Grabbing worksheets from various workbooks

    Hi,

    I have a code that aims to grab various worksheets from various workbooks based on worksheet names. Basically it takes the workbook names from col b and worksheet name from col c to import them in. however I am having an error on this line below:

    ws.Copy after:=wbkDest.Sheets(Sheets.Count)


    I have attached the relevant files with Test and Test2 being the files to be copied whilst MAIN is the consolidation file. Currently I am using excel 2003 for this macro. Thanks for anyone's help in advance

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by kchm_2000; 10-13-2011 at 04:36 AM.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,640

    Re: Grabbing worksheets from various workbooks

    Try this:

    Please Login or Register  to view this content.


    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    07-22-2010
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    85

    Re: Grabbing worksheets from various workbooks

    thanks a lot it works now

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,640

    Re: Grabbing worksheets from various workbooks

    You're welcome.

+ 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