Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Safe directory delete
Message
De
05/01/2009 03:38:15
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01370874
Message ID:
01370954
Vues:
16
Big Thank's
It's better than best (as usual).

BTW
Do you know about any way to scan direcctly from VFP.
Now the user must press on the scanner bottun or to open special scanner program.
Twain activeX, or any other way to call other program aoutomaticly (my scanner support 'Cancel','connected' and 9 func by button press.

Thanks in advance

>You don't have to change the current folder at all
>
>lcFolder = ADDBS("c:\tmpfox\")
>FOR i=1 TO ADIR(laFiles, lcFolder + "*.*")
>	ERASE (lcFolder + laFiles(i,1))
>ENDFOR
>
>
>>
>>I get The data path in the project start.
>>oApp.startdir=network\data\..
>>set defa to (oApp.startdir)..
>>
>>Now I want to delete entire files of temp directory (only files, not directory) on local computer.
>>
>>I use with the following code:
>>
local nloop,cfilename,cOutput
>>Local array aFiles(1)
>>cOutput='c:\tmpfox\'
>>set default to (cOutput)
>>nFiles=adir(aFiles)
>>If nFiles>0
>>	for nLoop=1 to nFiles
>>		cFilename=cOutput+aFiles[nLoop,1]
>>		delete file (cFilename)
>>	endfor
>>Endif
>>set default to (oApp.startdir)
>>return .t.
>>I afraid about any unexpected problem that will cause the 'set defa to local' to fail and the user will delete thr real data.
>>Thank's
Thank you
Chaim
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform