Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How many weeks in a month
Message
 
 
To
06/11/2007 15:43:58
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01266837
Message ID:
01267119
Views:
15
>Based on the procedure you sent me before:
>
>lnMonth = 10
>lnYear = 2007
>ldFirstOfMonth = DATE(lnYear, lnMonth, 1)
>lnWeeksPerMonth = MOD(WEEK(GOMONTH(ldFirstOfMonth,1),0,2)+52 - WEEK(ldFirstOfMonth,0,2), 52)
>? lnWeeksPerMonth
>

If we take that in account than 10/29/2007 does not belong to October. It belongs to the first week of November.
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform