Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Add time to date to make DateTime
Message
 
 
À
02/02/2017 18:43:43
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01647380
Message ID:
01647384
Vues:
40
>>Hi,
>>
>>Say I have a variable that contains a date. I want to add to it the current time and make the value DateTime type.
>>How do you do it? TIA
>
>
>m.Yesterday = DATE() - 1
>? VARTYPE(m.yesterday),m.yesterday
>m.yesterday = DTOT(m.yesterday) + SECONDS()
>? VARTYPE(m.yesterday),m.yesterday
>
First, thank you. Something is not working for me. Let me clarify. I want the value of (your example, m.Yesterday) to be converted to the DateTime that has the current time. For example, I want the variable to have:
tYesterday = '2017-01-31 18:49:111'

If you see my message to myself hopefully you will see what I mean.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform