Execute Command for 7-zip command line application

Post Reply
berniemok
Newbie
Posts: 7
Joined: Tue Sep 04, 2012 9:20 am

Execute Command for 7-zip command line application

Post by berniemok »

I am trying Execute Command for 7-zip command line application.


1. So I write a batch file with direct file names as below first.

cd "C:\01-Job Folder\7za920"

7za a -t7z test-a.7z readme.txt

It can work when I run in Windows 10, the "readme.txt" file can be zip with filename "test-a.7z"

2. Then I re-write the batch file for Execute Command use.

set arg1=&1
set arg2=&2
cd "C:\01-Job Folder\7za920"
7za a -t7z %arg2% %arg1%

(In the 7z command, the 7-zip file name comes first, then the source file name after. So I guess it is "%arg2" first, then "%arg1")

3. In the Execute Command Setting,

Execute Mode: Concurrent
Command or Path: (batch file location)
Argument": "%2" "%1"
Output: File at Path

3. When I run the flow, the incoming file has been put into Problem jobs. So may I ask how to correct this?

Many Thanks in advance.
Attachments
01-batch file content.JPG
01-batch file content.JPG (16.81 KiB) Viewed 3681 times
Malcolm Mackenzie
Member
Posts: 121
Joined: Wed Mar 22, 2017 5:05 pm
Location: London, UK
Contact:

Re: Execute Command for 7-zip command line application

Post by Malcolm Mackenzie »

Hi,
can you describe what your doing please.
Zipping files can be done in switch directly without a 3rd party app.
Using CLI in Execute Command and a bat file with variables you can use
https://www.enfocus.com/en/appstore/pro ... and-friend
Example
Screenshot 2020-05-05 at 12.00.44.png
Screenshot 2020-05-05 at 12.00.44.png (21.67 KiB) Viewed 3590 times
https://www.enfocus.com/manuals/UserGui ... mmand.html
Post Reply