If between to dates enter "x"

robocop1906

Board Regular
Joined
Jan 15, 2003
Messages
143
Hello, trying to figure out a formula that would enter an "x" in the sell if a cells value is between two dates. I tried the follownig formulat below. Thanks


=if(and(D12>=1/1/2011,if(D12<1/31/2011,"X","")
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
try this
Excel Workbook
EF
21/1/20111/31/2011
3X
Sheet1
Excel 2003
Cell Formulas
RangeFormula
E3=IF(AND(D12>=E2,D12),"X","")
 
Upvote 0
I think you would be better off to put the conditions in a cell rather than in the formula itself, in this case I used cells G12 and H12 to put the start date and the end date.

=IF(AND(D12>=G12,D12<=H12),"X","")
 
Upvote 0

Forum statistics

Threads
1,224,548
Messages
6,179,448
Members
452,915
Latest member
hannnahheileen

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top