How to ZIP specific files from a folder using Winzip command line? -


with command, i'm able zip files folders:

wzzip.exe -a -p -r c:\destinationpath\datafiles_20130903.zip c:\sourcepath\*.* 

but, folder has .dat,.bat,.txt,.xls files.i want zip .dat , .bat file.how this?

thanks.

use command (for particular scenario in question):

wzzip.exe -a -p -r c:\destinationpath\datafiles_20130903.zip c:\sourcepath\*.dat c:\sourcepath\*.bat 

for more command line options winzip refer following links:

winzip command line reference 1

winzip command line reference 2

to provide multiple file names can use @filename filename file contains list of files want include in zip file.

if making command configurable can ask user/ other program calling command select file extensions , write these selected extensions "filename" file using java code or other language prefer.

for example if user selects bat , dat , write "c:\sourcepath\*.bat" , "c:\sourcepath\*.dat" file(assume filename fileextensions.txt) , call command

wzzip.exe -a -p -r "c:\destinationpath\datafiles_20130903.zip" @"c:\sourcepath\fileextensions.txt" 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -