+ Reply to Thread
Results 1 to 3 of 3

check if number in once cell exists in a range of cells and if yes, format another cell

  1. #1
    Registered User
    Join Date
    05-11-2013
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    25

    check if number in once cell exists in a range of cells and if yes, format another cell

    I want to check if the number in one cell (eg.A1) has also been entered in one of a range of cells(eg.B1:F5) and if yes, I will conditionally format the pattern of cell G1 (which is the sell with these formatting rules).
    In Conditional Formatting, I can enter in "Format values where this formula is true" =$A$1=$B$1 and repeat this for $B$2 through to $F$5 each in a different rule. But I am sure there will be a way to do this in one formula and hence one rule. Can anybody help me please?

  2. #2
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: check if number in once cell exists in a range of cells and if yes, format another cel

    use the formula option and put =countif($B$1:$F$5,$a$1)
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  3. #3
    Registered User
    Join Date
    05-11-2013
    Location
    Australia
    MS-Off Ver
    Excel 2007
    Posts
    25

    Re: check if number in once cell exists in a range of cells and if yes, format another cel

    Thank you Martin, That works fine and I have also learnt a new function. Again, thank you.

+ 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