+ Reply to Thread
Results 1 to 8 of 8

Delete entire row based on specific criteria

  1. #1
    Forum Contributor
    Join Date
    03-11-2011
    Location
    Nepal
    MS-Off Ver
    MS Excel 2024
    Posts
    1,384

    Delete entire row based on specific criteria

    Hi
    I have two worksheet with name 'S' and 'D'.
    What I want is that-

    1.to remove entire row if worksheet 'S' column A contains the first letter P Or S

    2.to remove entire row if worksheet 'D' column T contains the first letter P Or S

    3.to remove entire row if worksheet 'S' column N contains the first letter Y

    Thanx as always in anticipation.

  2. #2
    Valued Forum Contributor
    Join Date
    11-26-2012
    Location
    Sydney
    MS-Off Ver
    2010
    Posts
    423

    Re: Delete entire row based on specific criteria

    Try this:
    Please Login or Register  to view this content.
    Last edited by mgs73; 05-08-2020 at 12:12 AM.

  3. #3
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2019 | 2021
    Posts
    14,958

    Re: Delete entire row based on specific criteria

    This assumes headers in row 1 of both sheets...
    Please Login or Register  to view this content.
    Good Luck...
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the [★ Add Reputation] to left of post window...
    Also....Add a comment if you like!!!!
    And remember...Mark Thread as Solved...
    Excel Forum Rocks!!!

  4. #4
    Forum Contributor
    Join Date
    03-11-2011
    Location
    Nepal
    MS-Off Ver
    MS Excel 2024
    Posts
    1,384

    Re: Delete entire row based on specific criteria

    Thanx a lot both worked except post#2 that deletes header which is in row 1 of worksheet 'D' else everything is fine.

  5. #5
    Forum Contributor
    Join Date
    03-11-2011
    Location
    Nepal
    MS-Off Ver
    MS Excel 2024
    Posts
    1,384

    Re: Delete entire row based on specific criteria

    One last thing,what will be revised code of post #3 if I have no 3rd criteria as mentioned in my post#1

  6. #6
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2019 | 2021
    Posts
    14,958

    Re: Delete entire row based on specific criteria

    what will be revised code of post #3 if I have no 3rd criteria
    Leave this snippet out...
    Please Login or Register  to view this content.
    except post#2 that deletes header which is in row 1
    Change red 1 to 2
    Please Login or Register  to view this content.
    Last edited by Sintek; 05-09-2020 at 04:44 AM.

  7. #7
    Forum Contributor
    Join Date
    03-11-2011
    Location
    Nepal
    MS-Off Ver
    MS Excel 2024
    Posts
    1,384

    Re: Delete entire row based on specific criteria

    Thanx a lot.

  8. #8
    Forum Guru Sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2019 | 2021
    Posts
    14,958

    Re: Delete entire row based on specific criteria

    pleasure...tx for 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. Macro or Formula to delete entire row based on multiple criteria
    By lucasc10 in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 01-05-2020, 05:06 PM
  2. [SOLVED] Marco to delete entire row based on value in specific column
    By djm601 in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 01-17-2013, 12:53 PM
  3. Macro - Move entire row to other tab based on specific criteria
    By thomasp in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-08-2013, 11:29 AM
  4. [SOLVED] Delete entire row based on 2 criteria
    By coopman64 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-13-2012, 03:38 PM
  5. Delete entire row based on criteria
    By D_N_L in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-08-2011, 09:13 AM
  6. Delete entire row from range based on criteria
    By uncleslinky in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-29-2011, 06:10 AM
  7. delete entire rows based on a criteria
    By acekargo in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-30-2008, 11:15 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