+ Reply to Thread
Results 1 to 8 of 8

Extract multiple sheets data into one sheet

  1. #1
    Registered User
    Join Date
    06-20-2014
    Location
    France
    MS-Off Ver
    2010
    Posts
    20

    Extract multiple sheets data into one sheet

    I would like to request some help, in creating macro which can read data from one/or more sheet and copy and paste it into another sheet, by matching up column A & B and Row 1, between the both sheets.

    I have monthly data stored in each sheet, named as May, June, July etc. I also have sheet called 'monthly' within the same workbook, where I would like to extract all monthly totals, from sheets july, June etc, into the 'Monthly' worksheet by matching up its names from Column A and B and row1 header with each sheet's names.

    The june,july worksheets have date1, date2 etc, columns with data and after those columns, there are the 'bs, rm, cm, cd, cl' columns, and these are the columns, I would like to use, to extract the numbers from and paste in the 'monthly' worksheet.

    My current issue, is that the 'bs, rm, cm..etc' columns are not fixed, due to the 'date1, date2 etc' columns can vary, for each month.

    For this current task, I was using a formula as shown below to extract the values into 'monthly' worksheet, however due to unfixed columns for 'bs, rm, cm... etc', I could not get the formula to work for the 'july' and 'Aug' months (i.e. extract data into 'monthly' worksheet, from the june&aug sheets).
    Please Login or Register  to view this content.
    I would like to request, if it is possible to use the formula below to re-create macro which can carry out this task, by extracting all the values from 'june, july, aug etc' sheet, into the 'monthly' sheet, at once.

    I have attached a sample workbook with example of data layout and desired output shown in monthly worksheet.
    data_extraction2.xls

    I hope i have explained my issue clearly, if not, then please free to ask further question, for any clarification.

    Thank you, for all your help.

  2. #2
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Extract multiple sheets data into one sheet

    Can you use this?

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    06-20-2014
    Location
    France
    MS-Off Ver
    2010
    Posts
    20

    Re: Extract multiple sheets data into one sheet

    Hi John,

    This great, it does exactly what I require. I have a small issue with the data content, which is, in Aug, June..etc worksheet there values under bs, cm...etc, which , are calculated using 'sum' formula and when I run the code, in the 'monthly' worksheet, the values get extracted as '#Ref'. Is this something easy to fix/or add in the code. Apology for the last minute trouble.

    if you require further detailed example, on the above request, please do let me know.

    Many thanks for your time.

  4. #4
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Extract multiple sheets data into one sheet

    Try:

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    06-20-2014
    Location
    France
    MS-Off Ver
    2010
    Posts
    20

    Re: Extract multiple sheets data into one sheet

    Hi John,

    Apology for not getting back to you sooner. I am sorry to inform, I was unable to run the updated macro successfully. The updated macro is throwing a "run-time error 1004", when I run it on example workbook file(data_extraction_2). I believe the error is within the first for loop of the code, hence when I run the macro, I get transferred to the 'June' worksheet.

    data_extraction3.xlsm
    I have attached the same sample data with 'June' sheet showing 'sum formula' values under the 'bs, rm, cm..etc' columns and the rest of the worksheets 'july' & 'aug', have just number values. The macro is attached in the workbook example.

    Thank you very much for updating the code in your previous post.

    Many thanks for your response and time in solving the issue.

  6. #6
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Extract multiple sheets data into one sheet

    Try:

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    06-20-2014
    Location
    France
    MS-Off Ver
    2010
    Posts
    20

    Re: Extract multiple sheets data into one sheet

    Thank you for your quick response back. The code works great! Many thanks for your hardwork and time into this.

  8. #8
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Extract multiple sheets data into one sheet

    You're welcome. Glad to help out and thanks for the feedback.

+ 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. How to extract data from multiple sheets
    By somnath6309 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-07-2013, 10:18 AM
  2. Macro to Extract Data from Multiple Sheets into One Sheet
    By BillW93 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-05-2013, 10:55 AM
  3. [SOLVED] How to code a macro to extract data from multiple sheets into one sheet?
    By likeabottle in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-21-2013, 04:51 PM
  4. Data extract from multiple sheets to one
    By ASH2707 in forum Excel General
    Replies: 4
    Last Post: 03-15-2011, 06:57 AM
  5. [SOLVED] Extract data from multiple sheets
    By jmenche in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-08-2005, 12:10 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