
Creator
2018-05-04
04:22 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Number of weeks in a months
I need to calculate the number of weeks in a specific month.
i m using a expression like
week(monthend(Date)) - week(MonthEnd(addmonths(Date,-1,0))) .
But its not giving a right answer.
Kindly help.
1,911 Views
2 Replies

MVP
2018-05-04
04:31 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Pooja, Week() waits for a date to return the week number this date belongs, you can do:
Ceil((monthend(Date) - MonthStart(Date))/7) // Or Floor instead of Ceil to round down
1,842 Views

Champion
2018-05-04
04:36 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
try this:
=week(MonthEnd(Date))-(week(MonthStart(Date))-1)
1,842 Views
