Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Output file with date&time stamp
Message
De
25/08/2004 19:30:14
 
 
À
25/08/2004 19:17:41
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00936444
Message ID:
00936446
Vues:
19
Hi Paul

Try this:
cDATE = SET('DATE')
SET PRINTER TO (CHRTRAN(tTOC(daTETIME()),' -:','')+'.TXT')
SET DATE (cDATE)
If the file's content is a string, you can create file like this:
cDATE = SET('DATE')
STRTOFILE(yourstring,(CHRTRAN(tTOC(daTETIME()),' -:','')+'.TXT'))
SET DATE (cDATE)
>Hello,
>
>I have codes to send an output file that supposed to be :
>
>ccyymmddhhmmss.txt will be 20040825183033.txt, datetime() is used maybe not sure
>
>please advise me how to do it:
>
>set print to c:\ccyymmddhhmmss.txt &&here to fix it
>set print on
>set console off
>select mytable
>set head off
>list off
>?"The process date is on "+dtoc(datetime())
>set print off
>set print to
>set console on
>
>At the end, my C: drive should have 20040825183033.txt
>
>TIA
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform