+ Reply to Thread
Results 1 to 4 of 4

VBA Need help with additional loop to copy range to different worksheet

  1. #1
    Registered User
    Join Date
    03-09-2014
    Location
    United States
    MS-Off Ver
    Excel 2013
    Posts
    5

    VBA Need help with additional loop to copy range to different worksheet

    I'm attempting to help a friend create a worksheet to consolidate his financial data. I've been able to muck my way through most of the VBA code by looking at examples on the forum.
    However, I cannot figure out how to add the last loop or where to place it.
    I can copy the values from the P&L sheet to the DATA sheet but I cannot discover a way to also pull the values from the BalSht sheet to the Data sheet.
    I think the BalSht loop will be almost identical to the "P&L sheet loop, and be placed just below it - but I'm not successful in multiple attempts and days of trying.
    How can I accomplish this? Please help!
    Here's the VBA code:

    Please Login or Register  to view this content.
    Excel file attached.
    Attached Files Attached Files

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: VBA Need help with additional loop to copy range to different worksheet

    Hello Old-One,

    You're post brings back memories. I was a bookkeeper for a few years.
    I have added a button to the data sheet to run the macro shown below. The macro is Module2. The attached workbook has these changes added to it.
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    03-09-2014
    Location
    United States
    MS-Off Ver
    Excel 2013
    Posts
    5

    Re: VBA Need help with additional loop to copy range to different worksheet

    WOW, Leith! That's AWESOME and so much cleaned than the code I developed!!!
    On behalf of both myself and my friend, THANK YOU so much!

  4. #4
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258

    Re: VBA Need help with additional loop to copy range to different worksheet

    Hello Old-One,,

    Glad I could help out. Hope you both have a great weekend.

+ 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. Loop through files in folder, copy range, Paste range to original workbook
    By knevil in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 03-09-2016, 05:33 PM
  2. [SOLVED] Loop to find data in a worksheet and copy into a different worksheet.
    By emily_k8_lewis in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-29-2013, 06:44 AM
  3. Loop and Copy to New Worksheet
    By mjali001 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-03-2013, 10:20 PM
  4. [SOLVED] VBA loop to copy a worksheet a number of times, assign name each time based on loop number
    By TBG in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-29-2012, 10:54 PM
  5. Copy Range with Additional Rows to New Workbook
    By Kim in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 03-28-2006, 12:30 AM

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