Forum Discussion
MarkShnier__You
Qrew Legend
5 years agoI could probably help you , but I don't have any pre-built formula that I can post. We would need to work one on one on a consulting basis.
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------
------------------------------
Mark Shnier (YQC)
Quick Base Solution Provider
Your Quick Base Coach
http://QuickBaseCoach.com
mark.shnier@gmail.com
------------------------------
JustinFinkelste
5 years agoQrew Member
Just looking for someone to point me in the right direction. Any help would be amazing!
------------------------------
Justin Finkelstein
------------------------------
------------------------------
Justin Finkelstein
------------------------------
- NeilSchneider5 years agoQrew CadetIt's been a while - but what you can do is:
Count the number of days between the start and end dates ToDays(startdate - enddate)
Divide that number by 7.
Multiply by 4 to get the work days in whole weeks
Then you need to adjust for the number of days that remain that are work days for example;
if there are 10 days in the period, and the first day of the period is Monday.
Mo Tu We Th Fr Sa Su Mo Tu We
Then you have 4 work days + Mo Tu We all of which are work days
So 7 total work days
Basically the adjustment is calculated as follows:
If the first date Mon
- If the number of remaining days is less than 7, add 3
- If the number of remaining days is less than 3, and all of them
...
That's the basic formula.
------------------------------
Neil Schneider
------------------------------- PaulPeterson25 years agoQrew TraineeThis should give you a good starting point:
If(DayOfWeek(endDate) > 3, 0, ToDays(NextDayOfWeek(startDate, 3) - startDate)) + (Int(ToDays(If(ToDays(endDate - NextDayOfWeek(endDate, 0)) = 7, endDate, NextDayOfWeek(endDate, 0)) - If(ToDays(NextDayOfWeek(startDate, 6) - startDate) = 7, startDate, NextDayOfWeek(startDate, 6))) / 7) * 4 )+ If(DayOfWeek(endDate) > 3, 0, ToDays(endDate - PrevDayOfWeek(endDate, 0)))
------------------------------
Paul Peterson
------------------------------- PaulPeterson25 years agoQrew TraineeSorry, just noticed an error.
Try This instead:
If(DayOfWeek(startDate) > 3, 0, ToDays(NextDayOfWeek(startDate, 3) - startDate)) +
(Int(ToDays(If(ToDays(endDate - NextDayOfWeek(endDate, 0)) = 7, endDate, NextDayOfWeek(endDate, 0)) - If(ToDays(NextDayOfWeek(startDate, 6) - startDate) = 7, startDate, NextDayOfWeek(startDate, 6))) / 7) * 4 )+ If(DayOfWeek(endDate) > 3, 0, ToDays(endDate - PrevDayOfWeek(endDate, 0)))
------------------------------
Paul Peterson
------------------------------