You are here:

# Excel/Conditional formatting formula

Question
In Column P2:P2444 there are a variety of dates.  In Column AG2:AG2444, I want the corresponding cells (that are otherwise blank/empty) to fill with red shading if the corresponding date in column P is between two dates. I've spent over an hour trying find something online but without success.  Thanks for your time/help.

select AG2:AG2444. With AG2 the active cell...
In conditional formatting formula:
=AND(P2>=DATEVALUE("1/1/14"),P2<=DATEVALUE("3/1/14"))

Change the dates, of course. If the dates are in cells, like K1,K2:
=AND(P2>=K1,P2<=K2)

Click Format, CLick Fill, Red.
Questioner's Rating
 Rating(1-10) Knowledgeability = 10 Clarity of Response = 8 Politeness = 10 Comment Thank you very much, Bob.

This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here

#### Bob Umlas

##### Expertise

I`m a Microsoft Excel MVP (Most Valuable Professional) and have been since the inception of the program in 1995. I can answer every kind of Excel question except: API, Importing/exporting to other programs (powerpoint, word,...) Also check out my in-person training link at http://www.thumbtack.com/ny/new-york/excel-training/

##### Experience

Worked with MS Excel since version 0.99 (on the Mac!). Was contributing editor to Excellence Magazine, having written >300 articles. John Walkenbach said of me "I finally met someone who knows as much about Excel as I do."

Publications
Excellence, The Expert, Microsoft

Education/Credentials
BA in math, Hofstra University, 1965

Awards and Honors
MVP
Led sessions for the Convergence 2004-2006 seminar on Excel tips & tricks