Forum Discussion
Alvin1007
Nov 07, 2022Copper Contributor
Display number of days in different months.
Dear All.
I have a timesheet.
When I entered the number: 1-12 as a month in a year, the table displayed the number of days in this month. But the issue is the days in a month are different so each time I will get the 28days, 30 days, or 31 days. If my table is fixed with rows, for example, 31 rows for the biggest days in a month, when I did the timesheet in Feb, I had to delete 3 days in my table.
I want to display an exact number of days corresponding with the different entered months.
Do I able to do it?
Alvin1007 SEQUENCE() function can give you desired result. See the attached file.
=SEQUENCE(DAY(EOMONTH(DATE(C2,B2,1),0)),,DATE(C2,B2,1))
2 Replies
- Alvin1007Copper ContributorDear Mr. Harun24HR.
How wonderful you are! Thanks a lot for your support. You are my life saver. It makes my timesheet easiest than ever.
Thanks again.