+ Reply to Thread
Results 1 to 3 of 3

When criteria is met in a column, check dup value in another column and copy row

  1. #1
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    When criteria is met in a column, check dup value in another column and copy row

    Hello. I have a file attach. I need vba to search for the word with "new" in the address in column D then when found look for the matches of ages in adjacent column C. Copy the entire row in sheet2.

    Example is in sheet2. New York with age 36 and all age of 36 will be copied. New Jersey with age 21 and all 21 will be copied and so on. Is it also possible that the "new" will be either in the front or end of the word when searching?

    Not all the duplicate age in column C will be copied. Just need to check the criteria in column D first before getting the dups. Tia.
    Attached Files Attached Files
    Last edited by dummy777; 05-29-2023 at 06:22 PM.

  2. #2
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: When criteria is met in a column, check dup value in another column and copy row

    Where I can find the code? Or attachment?

  3. #3
    Forum Contributor
    Join Date
    08-18-2018
    Location
    Canada
    MS-Off Ver
    365
    Posts
    151

    Re: When criteria is met in a column, check dup value in another column and copy row

    Quote Originally Posted by marcobrown View Post
    Before running the code, make sure to update the sheet names (Sheet1 and Sheet2) to match your actual sheet names. Also, ensure that you have a destination sheet (Sheet2) where the matching rows will be copied. Please note that the code assumes that the data starts from row 2, with row 1 being the header row. Adjust the code accordingly if your data starts from a different row.
    Where I can find the code or attachment?

+ 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 data from one or more column to another multiple column based on criteria
    By paradise2sr in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-08-2022, 03:12 AM
  2. [SOLVED] Check Column For Value, Then Copy / Paste Range If Criteria Met
    By amonty78 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-02-2018, 04:59 AM
  3. Copy cells in a column based on a specific criteria into another column
    By excelgeek1234 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-20-2017, 04:21 PM
  4. VBA Loop that check cells in a column(Range)then copy if criteria match
    By Eben in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-14-2015, 02:43 AM
  5. [SOLVED] Copy data from column to other sheets, based upon vlookup/criteria on column a
    By jedemeyer1 in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 03-27-2013, 04:01 AM
  6. Replies: 7
    Last Post: 10-01-2012, 09:20 AM
  7. [SOLVED] Copy Cells In One Column Based On Criteria In Another Column
    By hgteros in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 05-14-2012, 06:07 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