+ Reply to Thread
Results 1 to 3 of 3

VBA: Copy non-blank and paste to separate sheet ONLY blank cells (running list)

  1. #1
    Registered User
    Join Date
    08-10-2011
    Location
    Phoenix, AZ
    MS-Off Ver
    Excel 2007
    Posts
    16

    VBA: Copy non-blank and paste to separate sheet ONLY blank cells (running list)

    Hello!

    Hoping someone can help! I would like to find a formula that can do the following:
    Sheet 1 has data in columns A & B, each week a different amount of data will show.
    Sheet 2 is where I want the data to paste weekly in a running total in columns A & B.

    Therefore this is what I want:
    A macro that will copy columns A & B (ONLY THE CELLS THAT CONTAIN DATA) and then paste the data on the first line of blank data on Sheet 2.

    So for example:

    If week one had this on Sheet 1
    Dog
    Cat
    Bird

    Hit the macro and (Dog, Cat, Bird) will end up on lines 1-3 on Sheet 2.

    Then week two had this on Sheet 1
    Cow
    Pig
    Duck

    Hit the Macro again and will end up with lines 1-6 on Sheet 2:
    Dog
    Cat
    Bird
    Cow
    Pig
    Duck

    So in other words, the macro ONLY copies cells with data and pastes BELOW the last line of data in week 2 (first "open" cell).

    Would really appreciate help!!!

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: VBA: Copy non-blank and paste to separate sheet ONLY blank cells (running list)

    This is straightforward, but it will be much easier to get it right first time with a sample workbook, to make sure the code works with your actual data structure.

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  3. #3
    Registered User
    Join Date
    06-25-2014
    Location
    Budapest, Hungary
    MS-Off Ver
    2007
    Posts
    40

    Re: VBA: Copy non-blank and paste to separate sheet ONLY blank cells (running list)

    Assuming u have no empty lines inbetween:
    Please Login or Register  to view this content.

+ 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. Copy Paste Values Only From One Sheet Into Next Blank Row
    By Biegs101 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-20-2014, 01:52 PM
  2. Copy and paste values into next sheet. (blank cells contain formulas)
    By Vlad717 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-14-2013, 06:54 AM
  3. Replies: 18
    Last Post: 02-10-2013, 05:32 PM
  4. [SOLVED] VB code help- need copy cells in a row and paste to new sheet on next available blank line
    By Barbara Excel in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 11-27-2012, 03:11 PM
  5. Copy list - paste link - blank rows between cells
    By adame in forum Excel General
    Replies: 0
    Last Post: 06-08-2011, 10:56 AM

Tags for this Thread

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