+ Reply to Thread
Results 1 to 3 of 3

Delete entire row is cell contains a word except if the cell contains a specific phrase.

  1. #1
    Registered User
    Join Date
    08-21-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    24

    Delete entire row is cell contains a word except if the cell contains a specific phrase.

    Hi,

    I do have a long worksheet with a lot of information; out of which only a handful is needed.

    I was able to write a macro (from seeking help here itself) to delete all the rows that contained "HELP" in Column B, for example, and that was working fine so far.

    However, I have noticed that at times, I needed the information from cells that contained "HELP ME". Here is an illustration below:

    Original Data:
    Column B
    HELP! 123
    CAN I HELP?
    NO THANKS
    HELP ME 221
    PLEASE HELP ME
    HELP HELP HELP
    12345

    Wished Data:
    Column B
    NO THANKS
    HELP ME 221
    PLEASE HELP ME
    12345

    As you may notice, all the words cells that contained "HELP" was deleted except if the cell contains "HELP ME". My code so far is:

    Please Login or Register  to view this content.
    Any help is much appreciated, thanks!

  2. #2
    Valued Forum Contributor
    Join Date
    02-09-2012
    Location
    Mauritius
    MS-Off Ver
    Excel 2007
    Posts
    1,055

    Re: Delete entire row is cell contains a word except if the cell contains a specific phras

    Hi

    Try this macro:

    delrows.xlsm
    Click *, if my suggestion helps you. Have a good day!!

  3. #3
    Forum Expert nilem's Avatar
    Join Date
    10-22-2011
    Location
    Ufa, Russia
    MS-Off Ver
    2013
    Posts
    3,377

    Re: Delete entire row is cell contains a word except if the cell contains a specific phras

    as an option
    Please Login or Register  to view this content.

+ 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