+ Reply to Thread
Results 1 to 4 of 4

Help with code to copy cell to another sheet based on Criteria

  1. #1
    Forum Contributor
    Join Date
    06-17-2014
    Location
    london
    MS-Off Ver
    365
    Posts
    398

    Help with code to copy cell to another sheet based on Criteria

    Dear All
    I was wondering whether someone can help me with the following problem:
    I have attached a simple spreadsheet to demonstrate what I need to do:
    In the attached spreadsheet I need to look in sheet1 and if the scores in Col G is greater than zero then to copy the company name for that many times in sheet2 column A.
    For example Company Aa in sheet 1 has scored 1 so AA needs to be copied once in sheet2 A2 only once. Then company BB’s score is 2 so BB needs to be copied in sheet2 starting from first blank row in column A (i.e. A3), and CC to be copied 3 times to Sheet2 col A first available blank row (A5 , company DD should not be copied as it has score 0 and EE should be copied 5 times as it has score of 5 in Sheet 2. I just want to copy the company name and not the whole row.

    Hope this makes sense.

    Thanks in advance
    Attached Files Attached Files

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Help with code to copy cell to another sheet based on Criteria

    Try this:

    Please Login or Register  to view this content.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    Forum Contributor
    Join Date
    06-17-2014
    Location
    london
    MS-Off Ver
    365
    Posts
    398

    Re: Help with code to copy cell to another sheet based on Criteria

    Thank you so much. This worked perfectly

  4. #4
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Help with code to copy cell to another sheet based on Criteria

    You're welcome and thanks for the rep!

+ 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. [SOLVED] Copy cells from one sheet to another based on a certain cell criteria
    By Southbound10 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-21-2015, 08:57 PM
  2. Copy entire ROWS from one sheet to another based on cell CONTAINS criteria
    By ihatepivottables in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-16-2014, 09:32 AM
  3. [SOLVED] VBA Code to copy different data from one sheet to multiple sheets based on criteria
    By eharwood in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 10-08-2014, 02:22 PM
  4. Code troubles - Trying to copy a row to another sheet based on criteria, then delete
    By kurt1985 in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 02-21-2014, 10:48 AM
  5. Replies: 0
    Last Post: 07-16-2013, 05:22 AM
  6. Code to copy and paste row from one excel sheet to another, based on criteria
    By CamSeren in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-25-2013, 04:32 AM
  7. copy a row of data to new sheet based on a criteria using cell.offset
    By Naniboo in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-12-2010, 04:03 PM

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