+ Reply to Thread
Results 1 to 15 of 15

Conditional formating based on multiple criteria.

  1. #1
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Conditional formating based on multiple criteria.

    Hi

    I have two queries I am looking for help with please. Both are conditional formatting queries.

    The first is that I want to higlight a cell based on the date being older than say 6 weeks from today. However I have say six columns where date could be entered depending on which stage the job has reached. I only want date older than 6 weeks to be flagged if the cells after it do not contain any data. Just to complicate it slightly I need this to carry on every week so next week date 6 weeks before will then get flagged. Is this possible? (i'm using excel 2007)

    The second querry I have is can i format a cell so it is highlighted only if data has been entered this week?

    Thanks for any advice.

  2. #2
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    16,036

    Re: Conditional formating based on multiple criteria.

    Can you upload example workbook with several different examples (you can paint cells manually).
    Never use Merged Cells in Excel

  3. #3
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Here is example data. Site A was recieved within the last 6 weeks so is not flagged for that. The date is more than a week old so is also not flagged.

    The red cells are more than 6 weeks ago and have no date in the column to their right. Yellow are dates this week.

    Is it possible to do this automatically?
    Attached Files Attached Files

  4. #4
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    16,036

    Re: Conditional formating based on multiple criteria.

    Try for last 10 days to see does WEEKNUM criteria works as you planned
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Thanks for the reply, it seems to work other than cell C2, which shouldnt have any colour as it is less than 6 weeks old?

  6. #6
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Ah i see i have had a look at the formulas. Its red if it is the final number in the line. If there was a third condition saying If date is more than toady minus 35 days for example, make the cell blank would that work?

  7. #7
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    16,036

    Re: Conditional formating based on multiple criteria.

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

  8. #8
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    That works perfectly thanks so much for that, really appreciated!

  9. #9
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Sorry I have another question on this. The guys i am working with noticed that in certain cirumstaces we will sometimes have instances where a stage is skipped so only dates for say stage 1 and then stage 6 are entered.. Can i edit the formula for the red so that if there is data in any of the cells and not just the next one to the right, the formula will highlight only the last one?

  10. #10
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    16,036

    Re: Conditional formating based on multiple criteria.

    Here, try this (always one more column of table range and that one must not have number/date. In this case H column):
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by zbor; 06-12-2013 at 09:43 AM.

  11. #11
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Perfect again. Thank you.

  12. #12
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Hi,

    I've managed to apply the rules to my sheet with real data. For some reason though the red formula is not picking up any dates before this year in mine, but is working for the dates this year, as is the other rule. Is this a setting on the sheet that needs changing?

    The formula for mine I have is

    =(WEEKNUM(TODAY(),2)-WEEKNUM(N6,2)>=6)*ISNUMBER(N6)*(COUNT(O6:$Y6)=0)

    Thanks

  13. #13
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Still a little stuck with this so if anyone has any ideas they would be much appreciated.
    Last edited by mark.studley; 06-14-2013 at 05:18 AM.

  14. #14
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    16,036

    Re: Conditional formating based on multiple criteria.

    You'll need to go with real dates but you will loose for 'current week':

    Change number of days (now is 40):

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

  15. #15
    Registered User
    Join Date
    05-13-2013
    Location
    Wales
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Conditional formating based on multiple criteria.

    Brilliant that is working thank you again zbor.

+ 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