Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Zipping Files
Message
De
25/10/2002 06:28:14
 
 
À
25/10/2002 06:06:25
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00715324
Message ID:
00715330
Vues:
11
>I have a line of code like the following in which I'm trying to zip some files.
>
>STORE 'e:\files\test.zip' TO m.zipfile
>STORE ALLTRIM(&path_name +"*.*") TO m.fileszipped
>RUN c:\windows\pkzip.exe -ex m.zipfile m.fileszipped
>
>If I look through the debugger
>m.zipfile "e:\files\test.zip"
>m.fileszipped "c:\temp\*.*"
>
>But this does not create my zipfile. Not sure whats happening because
>the Dos box flash up to quick to see any errors.
>
>
>Anyone any ideas?

You need to expand the variables before issuing the run command. Try:
STORE 'e:\files\test.zip' TO m.zipfile
STORE ALLTRIM(&path_name +"*.*") TO m.fileszipped
cRunCommand = 'RUN C:\WINDOWS\PKZIP.EXE -ex ' + m.zipfile + ' ' +m.fileszipped
&cRunCommand
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform