Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Return the date in which ever format i've got to functio
Message
 
To
24/08/1998 06:21:53
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00129237
Message ID:
00129245
Views:
25
>say i've got yyyy/mm/dd or yy/mm/dd or mm/yy/dd or mm/yyyy/dd
>i 've to do calculations on year part and return the date in the same format as it was given to the function.

You can use GOMONTH() or convert the date to a string with DTOC(), cut out the year using RIGHT or LEFT, do your operation then rebuild the string and convert it back to a date using CTOD(). I prefer to just use GOMONTH() and pass a value 12 times the number of years I want to move. I did this to calculate the Thai year which is 2541. ;)

Eric K.
Previous
Reply
Map
View

Click here to load this message in the networking platform