![]() |
Count Inbetween dates
Hi
How do I show that a date in a row is inbetween a date. Say: I have a cell called 'Datecell' and I want to count each row with a date in the past 12 months of this date. How would I do this? I originally had =IF(DateCell-365<=E2,"Yes"). Although this counts everything in the past 12 months and gives it a 'Yes', it also counts everything after the date in the 'DateCell' and not inbetween the two dates. Anyone know a solution? Thanks |
Count Inbetween dates
Hi,
Try this =SUMPRODUCT((A1:A100<=TODAY())*(A1:A100=DATE(YEAR (TODAY())-1,MONTH(TODAY()),DAY(TODAY())))) -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Dave" wrote: Hi How do I show that a date in a row is inbetween a date. Say: I have a cell called 'Datecell' and I want to count each row with a date in the past 12 months of this date. How would I do this? I originally had =IF(DateCell-365<=E2,"Yes"). Although this counts everything in the past 12 months and gives it a 'Yes', it also counts everything after the date in the 'DateCell' and not inbetween the two dates. Anyone know a solution? Thanks |
Count Inbetween dates
Hi Mike
I need the formula to return a Yes statement as in the previous formula so I need =IF(DateCell-365<=E2,"Yes") but to count inbetween a date as opposed to _365. Thanks "Mike H" wrote: Hi, Try this =SUMPRODUCT((A1:A100<=TODAY())*(A1:A100=DATE(YEAR (TODAY())-1,MONTH(TODAY()),DAY(TODAY())))) -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Dave" wrote: Hi How do I show that a date in a row is inbetween a date. Say: I have a cell called 'Datecell' and I want to count each row with a date in the past 12 months of this date. How would I do this? I originally had =IF(DateCell-365<=E2,"Yes"). Although this counts everything in the past 12 months and gives it a 'Yes', it also counts everything after the date in the 'DateCell' and not inbetween the two dates. Anyone know a solution? Thanks |
Count Inbetween dates
It's still unclear exactly what you want, but here's an example of how you
do "in between": =IF(and(DateCell<E2,DateCell-365E2),"Yes",false) Regards, Fred "Dave" wrote in message ... Hi Mike I need the formula to return a Yes statement as in the previous formula so I need =IF(DateCell-365<=E2,"Yes") but to count inbetween a date as opposed to _365. Thanks "Mike H" wrote: Hi, Try this =SUMPRODUCT((A1:A100<=TODAY())*(A1:A100=DATE(YEAR (TODAY())-1,MONTH(TODAY()),DAY(TODAY())))) -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Dave" wrote: Hi How do I show that a date in a row is inbetween a date. Say: I have a cell called 'Datecell' and I want to count each row with a date in the past 12 months of this date. How would I do this? I originally had =IF(DateCell-365<=E2,"Yes"). Although this counts everything in the past 12 months and gives it a 'Yes', it also counts everything after the date in the 'DateCell' and not inbetween the two dates. Anyone know a solution? Thanks |
All times are GMT +1. The time now is 04:53 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com