Thanks for the reply. It actually answers part of my question but not completely.
What I need to do is use everything in the LIST as a variable.
So:
BEGINNING OF BATCH FILE
BEGIN LIST
File1.TXT
File2.TXT
File3.TXT
END LIST
wzzip -a -P -r tempfolder\myzip_file.zip VARIABLE
(more stuff in the batch file)
__________________________
In effect, I want the batch file to do this.
wzzip -a -P -r tempfolder\myzip_file.zip File1.TXT
wzzip -a -P -r tempfolder\myzip_file.zip File2.TXT
wzzip -a -P -r tempfolder\myzip_file.zip File3.TXT
The list changes all the time.
So another time the list may have 10 items in it.
BEGINNING OF BATCH FILE
BEGIN LIST
File1.COM
File2.BAT
File3.ASC
File4.ASC
File5.PGP
File6.001
File7.FIL
File8.TXT
File9.DLL
File10.EXE
END LIST
wzzip -a -P -r tempfolder\myzip_file.zip VARIABLE
______________
So in effect, I want the BAT file to do:
wzzip -a -P -r tempfolder\myzip_file.zip File1.COM
wzzip -a -P -r tempfolder\myzip_file.zip File2.BAT
wzzip -a -P -r tempfolder\myzip_file.zip File3.ASC
wzzip -a -P -r tempfolder\myzip_file.zip File4.ASC
wzzip -a -P -r tempfolder\myzip_file.zip File5.PGP
wzzip -a -P -r tempfolder\myzip_file.zip File7.FIL
wzzip -a -P -r tempfolder\myzip_file.zip File6.001
wzzip -a -P -r tempfolder\myzip_file.zip File8.TXT
wzzip -a -P -r tempfolder\myzip_file.zip File9.DLL
wzzip -a -P -r tempfolder\myzip_file.zip File10.EXE
I don't know how to have it look at a list to get assign the items IN THE LIST as a variable.
Thanks.
Main Topics
Browse All Topics





by: dbruntonPosted on 2002-11-22 at 21:55:33ID: 7486511
How many variables are there?
You can stuff them on the command line such as
Mybatchfile.bat alpha bravo charlie delta etc
Inside the batch file you would have lines such as
:start
if "%1"=="" goto end
wzzip -a -P -r tempfolder\myzip_file.zip %1
shift
goto start
:end
echo Processing done
This will work as long as you don't have a huge command line.