SOLVED

Automatic entries in cells based on a date range

Copper Contributor

Looking for help creating a formula that will do the following - 

Column A is start date

Column B is an end date

Column C is a number

The rest of the columns are dates that I want the number in column C to be automatically placed if the date falls in the range of columns A and B.

 

Thanks,

Stan

4 Replies
best response confirmed by allyreckerman (Microsoft)
Solution

@StantonSmith 

In D2:

=IF(AND(D$1>=$A2,D$1<=$B2),$C2,"")

Fill down and to the right (or vice versa).

See the attached workbook.

@StantonSmith 

Using Excel 365, a single formula

=IF((day>=startDate)*(day<=endDate),number,"")

entered into cell D2 will generate the entire 389x352 array.  What use it is, I have no idea.

image.png

@Hans Vogelaar

Thanks so much! saved me a lot of time

thanks! its for showing the amount of people processing over a date range and related to capacities. I know it is "analog" but I like to see the array before summing and making it into a chart.
1 best response

Accepted Solutions
best response confirmed by allyreckerman (Microsoft)
Solution

@StantonSmith 

In D2:

=IF(AND(D$1>=$A2,D$1<=$B2),$C2,"")

Fill down and to the right (or vice versa).

See the attached workbook.

View solution in original post