+ Reply to Thread
Results 1 to 8 of 8

Copying worksheets into one

  1. #1
    Registered User
    Join Date
    02-05-2010
    Location
    Warwickshire
    MS-Off Ver
    Excel 2003
    Posts
    4

    Smile Copying worksheets into one

    I'm trying to copy specific worksheets into one called Summary that I have already created (worksheets are Bathroom, Plumbing, Tiling, Plastering, Labour-Sundries). I need it to only copy the rows that have a 1 in column A from each sheet, and not copy the header row. I would also like it to copy the formatting and I would like it to start from row 10 in the Summary sheet so that I can put calculations in at the top.

    Please can someone help I've been trying different examples that I've adapted for hours with no success! Thank you

  2. #2
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: Copying worksheets in to one

    Hi mollysnuffy
    What do you have so far
    If the solution helped please donate to RSPCA

    Site worth visiting: Rabbitohs

  3. #3
    Registered User
    Join Date
    02-05-2010
    Location
    Warwickshire
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Copying worksheets in to one

    This is what I have so far but cant seem to get it to only look at column A where the value is 1. The code also seem quite long winded to the other examples I have found on the net but it kind of works (also haven't changed the sheet to be "Summary"). It is several few year since I dabbled with VB and other programming so I'm not 100% sure what does what, although some of what I was taught is making sense! Would appreciate any help.

    Thank you.
    Attached Files Attached Files
    Last edited by mollysnuffy; 02-05-2010 at 06:54 PM. Reason: Upload file

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Copying worksheets in to one

    This is how I would do that. It's a worksheet_activate macro, so each time you pull up the SUMMARY sheet, it will re-gather the data from the other sheets so it's always accurate.
    Please Login or Register  to view this content.
    This macro is installed into the sheet module.
    Attached Files Attached Files
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  5. #5
    Registered User
    Join Date
    02-05-2010
    Location
    Warwickshire
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Copying worksheets in to one

    Thank you so much for this. It does exactly what I want it to.

    I would also like to be able to run the macro to update the "Summary" sheet whilst I'm working on it rather than just on opening.

    I also need to add other worksheets that wont be in the same format and dont need the data to import into "Summary", how do I tell it to only look at Bathroom, Plumbing, Tiling, Plastering, Labour-Sundries.

    Thank you once again. Alison

  6. #6
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Copying worksheets in to one

    1) You would have to go to the other sheets to change the values and come back, so SUMMARY sheet will always be accurate within the workbook itself.

    2) This macro can replace the one in the workbook to fix the event to only the sheets named:
    Please Login or Register  to view this content.
    1) Right-click on the SUMMARY sheet tab
    2) Select VIEW CODE
    3) Delete the code in the window that appears
    4) Paste in the code given above
    5) Close the editor and save your workbook.

  7. #7
    Registered User
    Join Date
    02-05-2010
    Location
    Warwickshire
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Copying worksheets into one

    Thank you once again for your help. I have now included other worksheets and a letter template in the workbook to enable me to get quotes out to customers much quicker.

    I really appreciates the help.

    Kind regards Alison

  8. #8
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Copying worksheets into one

    My pleasure.

    If that takes care of your need, be sure to EDIT your original post, click Go Advanced and mark the PREFIX box [SOLVED].


    (Also, use the blue "scales" icon in our posts to leave Reputation Feedback, it is appreciated. It is found across from the "time" in each of our posts.)

+ 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