home *** CD-ROM | disk | FTP | other *** search
- dim ZipEXE, zipArchive, cmdLine, wpipath, root, destination
-
- set oFso=createobject("scripting.fileSystemObject")
- Set oShell = CreateObject("WScript.Shell")
- set objArgs = WScript.Arguments 'Command line arguments
-
- wpipath = oFso.getAbsolutePathname("") 'Get working directory where this script is run
- root=oFso.GetParentFolderName(wpipath)
-
- if WScript.Arguments.Count > 1 then 'WScript.Echo "Total number of arguments: " & WScript.Arguments.Count
- zipArchive = chr(34) + WScript.Arguments( 0 ) + chr(34)
- destination = chr(34) + WScript.Arguments( 1 ) + chr(34)
- else
- WScript.Quit
- end if
-
- zipEXE = chr(34) + wpipath + "\Tools\7z\7z.exe" + chr(34)
- cmdLine = zipEXE + " x " + zipArchive + " -aoa -o" + destination
-
- oShell.Run cmdLine, 0, True
-