+ Reply to Thread
Results 1 to 19 of 19

VB code help- need copy cells in a row and paste to new sheet on next available blank line

  1. #1
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    VB code help- need copy cells in a row and paste to new sheet on next available blank line

    Guys

    looking for some help.

    I need to code the following

    To highllight a cell in column A
    i then need to select a number of non contiguous cells in that row and past them into another worksheet in the same workbook
    the pasted cells can be pasted either contiguous or non doesnt matter

    thanks in advance

    Barbara
    Last edited by Barbara Excel; 11-27-2012 at 03:11 PM.

  2. #2
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    NEED A BIT MORE INFO...
    What type of cells will you be pulling, and for what point?

  3. #3
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    cells will be date, text and numbers
    they are to prevent user having to dupe entry from one sheet to another
    same data to be transferred from one sheet to another, but transferred to the next available blank line on the new sheet

    hope thats helps

  4. #4
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    Can you attached a sample workbook?
    Cant quite get the just...
    So, say A1,B1,C1 and D1 need to be transferred to next available line in Sheet2 be it row 1, 5 , 8 or 12?
    Will they always be the same number of cells? in the same order? etc?
    Last edited by Legend Rubber; 11-27-2012 at 10:53 AM. Reason: add detail

  5. #5
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    Here is attachment hope it helps
    Attached Files Attached Files

  6. #6
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    so you do not want to copy the cells that are not blue? or can they be copied as well?

  7. #7
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    HI
    no i need to copy the blue cells from copy from
    and paste them to the red area in paste to

    its not the whole row just the blue cells

  8. #8
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    that makes it harder...
    Will the non-blue cells in copy from be blank or have other data in them?

  9. #9
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    they will have data in them

  10. #10
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    There are too many variables here...
    Will it always be columns B C E G and I that get copied...
    Please specify mroe thoroughly what you are trying to accomplish...

  11. #11
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    would it help if the cells to be copied are only columns 12345 and get pasted to 12345 columns on the copied to sheet on the next available blank line?

  12. #12
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    yes it would help greatly...

  13. #13
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    ok cool can you help me with that?

  14. #14
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    yes, but i am still missing some info...
    Will the blue spots always be in the same spot?

  15. #15
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    yes in column but maybe in a different row, the row to be determined by the user selecting the first cell of the row they want to copy blue cells from

  16. #16
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    Is this like what you are looking for?
    CopyInfo.xlsx.xlsm

  17. #17
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    if that solved your issue, click solved, and the star under my name if i helped...

  18. #18
    Registered User
    Join Date
    05-15-2011
    Location
    Dublin, Ireland
    MS-Off Ver
    Excel 2007, Excel MAC 2008
    Posts
    64

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    Thanks for that- that is perfect
    I appreciate your help

    Regards
    Barbara

  19. #19
    Forum Contributor Legend Rubber's Avatar
    Join Date
    09-21-2012
    Location
    Tillsonburg, Ontario
    MS-Off Ver
    Excel 2010
    Posts
    392

    Re: VB code help- need copy cells in a row and paste to new sheet on next available blank

    no problem, dont forget to mark as solved...

+ 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