Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
There has to be an easier way!!!!!
Message
 
To
28/12/2006 14:20:26
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01180722
Message ID:
01180729
Views:
12
>>It needs to reside in our module. Basically I am determining the day number and if it is 1-7 then it is in the fist week of month, 8-14 in second week of month etc.
>>Just seems like there should be something simple.
>>
>>Thanks for the reply
>
>
>? int((lnDayOfMonth + 6) / 7)
>
Okay, but lets say I want to get the 2nd Tuesday of July, 2007. Presently I am determining the week day of 07/01/2007 and adding to it find the First Tuesday of July and then adding another 7 days. So in this case DOW() gives me a Sunday (1), add 2 and determine that July 3 is the 1st Tuesday, then add 7 to get the 10th which is the 2nd Tuesday.

Works but seems kind of clunky. Was hoping that I am missing the obvious.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform