Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to display only the date from a date time field
Message
De
30/04/2004 10:12:25
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
29/04/2004 19:19:44
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00899542
Message ID:
00899752
Vues:
14
>Hi!
>
>DO you guys have in Visual FoxPRO something equivalent to DateValue() in Visual Basic? In VB this function returns the Date of a DateTime Field, or object given as a parameter, is only a way I know in VB, I dun know about in FoxPro!
>
>here is an example:
>
>Dim MyReturnedDate as String
>MyReturnedDate = DateValue(Now()) ' Return a date.
>
>
>Remarks
>If the date argument includes time information, DateValue doesn't return it. However, if date includes invalid time information (such as "89:98"), an error occurs.

In VFP it's :
MyReturnedDate = ttod(datetime())
where MyReturnedDate is a date type.

MyReturnedDate = dtoc(ttod(datetime()))
where MyReturnedDate is char type. There are plenty of other conversion functions.
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
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform