Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Converting weird date format
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00048265
Message ID:
00048500
Views:
20
Thanks Jim.


>Here's a small code segment that will convert this data to a VFP date;
>
> PROCEDURE ConvDate
> LPARAMETERS pcDate
>
> LOCAL ldDate, lcYear, lcOldDateSet, lnDays
> lcOldDateSet = SET("DATE")
> SET DATE AMERICAN
> ldDate = CTOD("01/01/"+ STR(1900 + STR(LEFT(pcDate,3),4,0) )
> lnDays = VAL(RIGHT(pcDate,3),3,0)
> RETURN ldDate + lnDays - 1
Al Williams

Anola MB, CANADA
Previous
Reply
Map
View

Click here to load this message in the networking platform