Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date value from year, month and day numbers in VFP5
Message
De
24/08/2001 12:24:43
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00548656
Message ID:
00548759
Vues:
9
>>VFP6 has a function that returns a date from year, month and day numbers - i.e. DATE(1998,2,28) will return 02/28/1998. Is there a better way in VFP5 than to build a date string from the values and pass it to the CTOD function?
>
>I don't know if it's better or not but it doesn't involve string functions and is SET DATE independent
lnYear = 1998
>lnMonth = 2
>lnDay = 28
>? Gomonth({0001/0001/0001}, (lnYear-0001)*12 + lnMonth-1) + lnDay-1
>
Sergey,
date(lnYear,lnMonth,lnDay) would be shorter but VFP5 he says.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform