+ Reply to Thread
Results 1 to 6 of 6

Running a macro and making it paste into the next blank cell.

  1. #1
    Registered User
    Join Date
    08-12-2010
    Location
    Orlando,Florida
    MS-Off Ver
    Excel 2007
    Posts
    19

    Running a macro and making it paste into the next blank cell.

    I have a problem with a macro that I have used in my spreadsheet.

    The problem is that when I use a macro I have created to copy and paste cells onto another sheet it is constantly overwriting the data when it needs to be constantly adding new information every time that the button is clicked, I need the button to paste below what has already been pasted when the button has previously been clicked.

    My question basically is:
    What coding do I need to insert into the macro to make it paste into the next available blank cell and not overwrite what has already been done?
    Last edited by CAMTHEMAN20; 08-12-2010 at 10:10 PM.

  2. #2
    Forum Contributor
    Join Date
    04-21-2007
    Location
    Lima, Peru
    MS-Off Ver
    2000, 2007, 2010
    Posts
    674

    Re: Running a macro and making it paste into the next blank cell.

    Hi

    You can use the following code, set to use column a, to find the last row plus one and then use the variable in your code.

    Please Login or Register  to view this content.
    Regards

    Jeff

  3. #3
    Registered User
    Join Date
    08-12-2010
    Location
    Orlando,Florida
    MS-Off Ver
    Excel 2007
    Posts
    19

    Re: Running a macro and making it paste into the next blank cell.

    ok where would you suggest placing it in this code:


    Please Login or Register  to view this content.
    Last edited by CAMTHEMAN20; 08-12-2010 at 09:45 PM.

  4. #4
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Running a macro and making it paste into the next blank cell.

    Hi CAMTHEMAN20

    Please wrap your code in code tags, before the moderators get you...

    Forum rules
    3. Use code tags around code. Posting code without them makes your code hard to read and difficult to be copied for testing. Highlight your code and click the # button at the top of the post window. If you are editing an existing post, press Go Advanced to see the # button.

    Cheers

  5. #5
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Running a macro and making it paste into the next blank cell.

    Thanks

    Try this
    Please Login or Register  to view this content.

    At first sight it seems to do what your code is asking.

    Check it out, I might have missed something.

    Hope this helps
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  6. #6
    Registered User
    Join Date
    08-12-2010
    Location
    Orlando,Florida
    MS-Off Ver
    Excel 2007
    Posts
    19

    Re: Running a macro and making it paste into the next blank cell.

    It works...I also got a response for somebody else with the same thing.

    But thank you for you time and knowledge.

+ 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