Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to Delete Folders created prior to some date
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01003065
Message ID:
01003184
Vues:
21
>VFP6 I have code to delete all the files in a folder greater than some number of days ago. But I also want to delete the folders that were created > than some number of days ago. How to do?
>
>
>arraynum=ADIR(aTemps,ctables)
>FOR i = 1 TO arraynum
>   if atemps(i,3)+20 < DATE()	&& last modified date was over 20 days ago
>	   cFile=aTemps(i,1)
>	   DELETE FILE (cpath+cFile)
>   endif	
>ENDFOR
>
Also take a look at XDIR File #25487 also
_______________________________________________________________
Testing displays the presence, not the absence of bugs.
If a software application has to be designed, it has to be designed correctly!
_______________________________________________________________
Vladimir Zografski
Systems Analyst
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform