Results 1 to 5 of 5
  1. #1
    4 Star Lounger
    Join Date
    Nov 2002
    Location
    London, Gtr London, England
    Posts
    496
    Thanks
    8
    Thanked 0 Times in 0 Posts

    Conditional Formatting & wild cards (2003 sp2)

    Dear Loungers,

    Is it possible to use wild card in conditional formatting I can't find anything that says how or a way to make it work so maybe not but does someone know for sure?

    What I am trying to do logically is something like make it red if like "y" plus anything else e.g. y1, y2, yx

    thanks............. liz

  2. #2
    Silver Lounger
    Join Date
    Jul 2001
    Location
    Ottawa, Ontario, Canada
    Posts
    1,609
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Conditional Formatting & wild cards (2003 sp2)

    Hi Liz
    For cell A1, set the Condition to "Formula is" then
    =LEFT(A1,1)="y"
    The conditional formatting can be copied to other cells using the Paste Special feature.
    Regards
    Don

  3. #3
    4 Star Lounger
    Join Date
    Nov 2002
    Location
    London, Gtr London, England
    Posts
    496
    Thanks
    8
    Thanked 0 Times in 0 Posts

    Re: Conditional Formatting & wild cards (2003 sp2)

    Don,

    Thanks that will work well in this case. As a general question do you think wild cards are usable in condotion formatting?

    liz

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Conditional Formatting & wild cards (2003 sp2)

    I don't think you can use wildcards, but you can use Formula Is in combination with a formula to specify any kind of condition you like. For example, if you want to highlight or otherwise format a cell differently if its value contains a y in any position, you can use the formula
    <code>
    =NOT(ISERROR(SEARCH("y",A1)))
    </code>
    in Conditional Formatting.

  5. #5
    WS Lounge VIP sdckapr's Avatar
    Join Date
    Jul 2002
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    11,225
    Thanks
    14
    Thanked 342 Times in 335 Posts

    Re: Conditional Formatting & wild cards (2003 sp2)

    Just to expand and clarify the various posts and the "wildcard"
    Don's
    <pre>=LEFT(A1,1)="y"</pre>

    is equivalent to "y*" And
    <pre>=right(A1,1)="y"</pre>


    is equivalent to "*y"

    Hans' formula:
    <pre>=NOT(ISERROR(SEARCH("y",A1)))</pre>

    is equivalent to "*y*"

    Of course you can replace "y" with a different string eg "abc" to make the equivalent "*abc*" (with the left/right the number must be changed to the lenght of the string (3 in the case of "abc"

    Steve

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •