+ Reply to Thread
Results 1 to 5 of 5

Conditional Formatting Formulas for Multiple Dates

  1. #1
    Registered User
    Join Date
    02-28-2011
    Location
    Bournemouth, England
    MS-Off Ver
    Excel 2010
    Posts
    16

    Conditional Formatting Formulas for Multiple Dates

    This is my very post so apologies in advance if I leave out any details needed. I am using Conditional Formatting in Excel 2010 and trying to create a calendar which I can enter my key financial dates and it will colour code the relevant dates on the calendar. I am really struggling with the formula required to highlight the 22nd of each month in the same colour and preferably the last working day before if the 22nd is a weekend.

    I have tried various different formulae today with no success. Am I taking the best approach or should I be looking at VBA? Please help I do not have much hair and even less after today

    I have attached the workbook I have prepared and the dates that need to be displayed on the calendar are in AD10:AD21 although these do not necessarily need to be used if another way can be found to reach the same answer.
    Attached Files Attached Files
    Last edited by smart_as; 03-02-2011 at 06:05 PM.

  2. #2
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Conditional Formatting Formulas for Multiple Dates

    Select A20:W52 and In conditional formatting

    =IF(WEEKDAY(A20,2)=5,OR(DAY(A20)=20,DAY(A20)=21),IF(WEEKDAY(A20,2)<6,DAY(A20)=22))
    Format appropriately
    Does that work for you?
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  3. #3
    Registered User
    Join Date
    02-28-2011
    Location
    Bournemouth, England
    MS-Off Ver
    Excel 2010
    Posts
    16

    Re: Conditional Formatting Formulas for Multiple Dates

    Hey ChemistB that works to a degree. It does not currently conditional format April cell N23 or July cell N32 in the same way. I have formatted the cells in the same manner as the others. If you amend the date selection for the calendar you will see that this issue is not consistent to any one date block it will move around the calendar.

    Please advise. Your help is greatly appreciated.

  4. #4
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Conditional Formatting Formulas for Multiple Dates

    oops, missed the option of it being friday and the date being the 22nd

    =IF(WEEKDAY(A20,2)=5,OR(DAY(A20)=20,DAY(A20)=21, Day(A20)=22),IF(WEEKDAY(A20,2)<6,DAY(A20)=22))

    How's that work?

  5. #5
    Registered User
    Join Date
    02-28-2011
    Location
    Bournemouth, England
    MS-Off Ver
    Excel 2010
    Posts
    16

    Re: Conditional Formatting Formulas for Multiple Dates

    Hi ChemistB that worked. Thanks a lot for help much appreciated.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

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