I have tried the formula to generate dates between start date and end date and it is not working properly.. I would need help here
CodePudding user response:
If you have an up-to-date version of Excel, you will have the very useful SEQUENCE() function. It generates a dynamic array of numbers.
For an inclusive range (including Start and End dates), use the formula:
=B2 SEQUENCE(1 B3-B2,,0)
For an exclusive range (excluding Start and End dates), use the formula:
=B2 SEQUENCE(B3-B2-1)
The result is a dynamic array of dates, which will grow or contract as the Start and End dates are changed.


