+ Reply to Thread
Results 1 to 10 of 10

Conditional formatting formula with 'contains' text...not exact text

  1. #1
    Forum Contributor
    Join Date
    02-26-2009
    Location
    Canada
    MS-Off Ver
    Excel 2013
    Posts
    209

    Conditional formatting formula with 'contains' text...not exact text

    Right now I'm using a formula in conditional formatting that reacts if a cell has the value of text "have". But I'd like the formula to function if the cell contains "have" as well as other text...example "have 3" would still trigger it. Right now this formula does not do that...

    =D3="Have"

    Is this possible with conditional formatting...or only for exact phrases?

  2. #2
    Forum Expert
    Join Date
    01-05-2013
    Location
    Singapore
    MS-Off Ver
    H&B2016 & H&B2021
    Posts
    3,069

    Re: Conditional formatting formula with 'contains' text...not exact text

    Try: =MATCH("*have*",D3,0)

  3. #3
    Valued Forum Contributor
    Join Date
    11-29-2022
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    435

    Re: Conditional formatting formula with 'contains' text...not exact text

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    02-26-2009
    Location
    Canada
    MS-Off Ver
    Excel 2013
    Posts
    209

    Re: Conditional formatting formula with 'contains' text...not exact text

    I tried the =ISNUMBER(SEARCH("have"),d3)) and get an error "too few arguments for this function"

    formula =MATCH("*have*",d3,0) appears to do the trick! Thanks everyone!

  5. #5
    Valued Forum Contributor
    Join Date
    11-29-2022
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    435

    Re: Conditional formatting formula with 'contains' text...not exact text

    Quote Originally Posted by unclejemima View Post
    I tried the =ISNUMBER(SEARCH("have"),d3)) and get an error "too few arguments for this function"

    formula =MATCH("*have*",d3,0) appears to do the trick! Thanks everyone!
    Sorry, typo :/
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  6. #6
    Forum Expert
    Join Date
    01-05-2013
    Location
    Singapore
    MS-Off Ver
    H&B2016 & H&B2021
    Posts
    3,069

    Re: Conditional formatting formula with 'contains' text...not exact text

    thomglea's formula can be shortened to =SEARCH("have",D3)).

  7. #7
    Valued Forum Contributor
    Join Date
    11-29-2022
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    435

    Re: Conditional formatting formula with 'contains' text...not exact text

    Quote Originally Posted by josephteh View Post
    thomglea's formula can be shortened to =SEARCH("have",D3)).
    Unfortunately, it cannot :/ if "have" does not exist, the formula results in #VALUE! error. The ISNUMBER will return TRUE or FALSE.

  8. #8
    Forum Expert
    Join Date
    01-05-2013
    Location
    Singapore
    MS-Off Ver
    H&B2016 & H&B2021
    Posts
    3,069

    Re: Conditional formatting formula with 'contains' text...not exact text

    Have you tried? CF does not require error flagging.

  9. #9
    Valued Forum Contributor
    Join Date
    11-29-2022
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    435

    Re: Conditional formatting formula with 'contains' text...not exact text

    Hope this image uploads, if not, I will try again.
    -edit removed image
    Last edited by thomglea; 04-07-2024 at 01:05 AM.

  10. #10
    Valued Forum Contributor
    Join Date
    11-29-2022
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    435

    Re: Conditional formatting formula with 'contains' text...not exact text

    Blah, nevermind. Conditional Formatting. Yeah, that will return the true or false I guess. Still do not like formulas that evaluate to errors tho /shrug

+ 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. Replies: 4
    Last Post: 03-21-2024, 06:28 PM
  2. [SOLVED] Conditional Formatting based on an exact or non-exact match from another sheet
    By gdarling in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-30-2024, 03:02 AM
  3. Replies: 6
    Last Post: 11-19-2018, 09:46 AM
  4. Formatting Cells with Date or Text Values in a Conditional Formatting Formula
    By Phil Hageman in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-15-2014, 09:36 AM
  5. [SOLVED] Conditional formatting to mark cells with on text strnig but lacking another text string
    By KArnoldColumbia in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-14-2013, 04:15 PM
  6. [SOLVED] function IF to return text based if text contains exact text
    By in nomine noctis in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-05-2013, 06:25 AM
  7. Conditional formatting - formula=text
    By duckboy1981 in forum Excel General
    Replies: 3
    Last Post: 09-16-2009, 11:36 AM

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