+ Reply to Thread
Results 1 to 16 of 16

Conditional Formatting based on 2 matching criteria

  1. #1
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Conditional Formatting based on 2 matching criteria

    ok, Sooo, I've been searching for a while now and after a lot of trial and error I have not been able to successfully apply the conditional formatting.

    I need to have 2 criteria match in order to have the cell colored blue.

    'sheet1'!a1 needs to match in column 'sheet2'!f:f
    and
    'sheet1'!c3 needs to match in column 'sheet2'!a:a

    If both values match then I want to color 'sheet1'!c11 blue.

    I'm also not sure how this will work when the 'sheet1'!c3 value will have to adjust to c4, c5, c6 etc as the corresponding cells to be highlighted (c11:nc3) continue along..... make sense?

  2. #2
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    Cheers!
    Deep Dave

  3. #3
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    Sample.xlsx

    OK, so there is a "Desired Result" sheet that shows you how I want the "Test Timeline" sheet to look.

    I just need to know how to set up the conditional formatting based on the 2 matching criteria that I mentioned above.

    I'm having a hard time deciding how to word all of this so please forgive me.

  4. #4
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    So basically you want 'sheet1'!c11 blue even If 1 row matches both criteria?

  5. #5
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Give this a Try

    On 'sheet1'!c11 use the below formula in conditional formatting.

    =SUMPRODUCT(('Daily Report Summary'!$A$2:$A$2000='Test Timeline'!$C$3)*('Daily Report Summary'!$F$2:$F$2000='Test Timeline'!$A$1))>0

  6. #6
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    I'm not sure I understand your question, but let me try to explain myself a bit better.

    I think the confusing part is that I need the Date found in 'sheet1'!3:3 has to match in 'sheet2'a:a. But that's only important if in that same row I find a match for 'sheet1!a1 against 'sheet2'!f:f.

    However the date value will change in every cell in my range of cell included for the conditional formatting.

    As I was typing this I thought it might help to copy and paste my date values from 3:3 down to 11:11 and simply "hide" them. I thought it might make it easier to do the matching that way.

    Does this help at all?

  7. #7
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Did you try the formula in Post #5

  8. #8
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    Actually I didn't see that til you mentioned it.

    I just tried it and I didn't see anything "happen". I didn't get an error though either.

    What is that supposed to accomplish?

  9. #9
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    It Matches the Date and The Value from the Drop Down in Sheet2, even If 1 row matches both the criteria, the CF will be activated..

  10. #10
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    OK that makes sense, but does that address the fact that the date value will change across the range of cells to be conditionally formatted?

    Example: The date for DS11 (5/1/2013 found above in DS3) will be different than the date for EX11 (6/1/2013 found above in EX3)

  11. #11
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    I think I got it! I removed the "$"s from the $C$3 after reading about how the CF works and that looks like it did the trick!

    I'm cross-checking the results now but at first glance it looks good!

  12. #12
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Great! Let me know if you need further help

  13. #13
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    I certainly will! Sooo grateful over here!

    I'll need to have a phone convo tomorrow morning to see what the client thinks. I may have to add in a 3rd criteria to match against. Would I just add another * followed by the next criterion assuming that we're just trying to return the value greater than "0", which would be a 1 since the value returned on each match is a "1" and if any of them are a "0" then the whole thing would be a "0"?

  14. #14
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Only if all the 3 criteria are true, only then it returns 1..

  15. #15
    Registered User
    Join Date
    01-24-2014
    Location
    Florida
    MS-Off Ver
    Excel 2010
    Posts
    32

    Re: Conditional Formatting based on 2 matching criteria

    OK, I've successfully carried out the rest of what I was trying to do by adding the 3rd dimension to the SUMPRODUCT formula. I was hoping to be able to copy/paste all of the blue cells so that I can remove the conditional formatting when I'm all finished. Is there a way to do this? I've tried a couple of different methods and haven't had any luck. I'll keep poking around in the meantime.

  16. #16
    Forum Expert NeedForExcel's Avatar
    Join Date
    03-16-2013
    Location
    Pune, India
    MS-Off Ver
    Excel 2016:2019, MS 365
    Posts
    3,879

    Re: Conditional Formatting based on 2 matching criteria

    Try this

    Press F5 > Special & Select Conditional Formats on this window

    111.JPG

    This will select all the cells that are Conditionally Formatted.. Then you can go ahead and copy & paste as required..

    Hope this is what was required. If not, please clarify further..

+ 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. [SOLVED] Use Conditional Formatting on a Cell Based on matching a value in a range
    By fablhof in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 07-25-2015, 09:28 PM
  2. Replies: 4
    Last Post: 07-25-2014, 05:17 AM
  3. [SOLVED] Matching duplicates based on multiple criteria, conditional formatting?
    By Jaqjaq in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-23-2013, 02:42 PM
  4. [SOLVED] Count cells with date criteria matching conditional formatting colour
    By summer2010 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-07-2013, 04:34 AM
  5. Replies: 7
    Last Post: 03-24-2013, 10:30 AM
  6. [SOLVED] Conditional Formatting based on 2 criteria
    By SantosJ in forum Excel General
    Replies: 2
    Last Post: 05-23-2012, 05:11 AM
  7. Replies: 2
    Last Post: 08-27-2011, 03:05 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