In sheet 'Leave' I have a row B49:CP49 that contains dates of the month B49 formula is…
- User
In sheet 'Leave' I have a row B49:CP49 that contains dates of the month
B49 formula is '=18'. A18 is the start date of the current month C49 formula is '=18 + 1' to get the next day This increment goes on to CP49 with a formula of '=18 + 92'
Unfortunately this method of writing month dates into the row B49:CP49 creates problems for other functions of my sheet.
I want a solution that will write that dates to the row B49:CP49 when I choose always starting B49 with the first day of the current month.
- Assistant
To write dates dynamically into your specified range (B49:CP49) based on your start date in
A18, you can use theSEQUENCEfunction (if you're using Excel 365 or Excel 2021, which supports dynamic arrays). TheSEQUENCEfunction allows you to generate a series of numbers or dates without needing to manually set up each individual cell.Here’s how you can do it:
-
In B49, use the following formula:
=SEQUENCE(1, 93, $A$18, 1)
-