This can be done by combining the SEQUENCE function with the EDATE and EOMONTH functions, as explained below.
The SEQUENCE function
TheSEQUENCE functiongenerates a list of sequential numbers in an array.
In all cases, EDATE returns the first of the month since the start date is also the first.
These are Excel dates in theirraw serial number format.
EOMONTH works just like the EDATE function.
The result is exactly the same.
The plus sign (+) is needed before the spill range in this case.
Without it, the formula will return a #VALUE!
Some older functions, like EOMONTH, “resist” spilling when provided with a range.
This limitation comes from certain functions expecting a single value instead of a range.
error is essentially reporting the range as an unexpected value.
For an overview, seeDynamic Array Formulas in Excel.
We then concatenate a “Q” to the output.
The array can be one dimensional, or two-dimensional, determined byrowsandcolumnsarguments.