Issue While Using 7za.exe

Discuss RoboTask here
Post Reply
feliciaIII
Posts: 2
Joined: Wed Feb 25, 2009 11:56 am

Issue While Using 7za.exe

Post by feliciaIII »

Hello everybody, recently I tried to use the 7-Zip Command Line Application with RoboTask 3.2.1. It worked very well until I wanted to encrypt my archives with a variable value. My commandline looks like this (in my batch I use another variable for the -p Argument. I inserted the " because the password could contain spaces.)(C:\Programme\7-Zip\7za.exe) ApplicationParameters: "a "C:\Dokumente Und Einstellungen\Felix\Desktop\Hochladen\{FILENAME_O}.7z" -mx9 -mhe "{ORDNER}\{FILENAME_I}" -p"{FILENAME_I}""so far so good, the archives are being created. but when I try to open them again, I get an "wrong password" error. I tried to use this command without the " but got exactly the same error with every Archive. However, when setting -p"testeinszwei drei4.5x6"while leaving the rest unchanged, it works, even with encrypted filenames. Can anyone please give me suggestions? I need these variable Passphrases for every single file :-(thank you, Greets from Dresden, Germany - feliciaIII
Oleg
Site Admin
Posts: 3202
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Issue While Using 7za.exe

Post by Oleg »

Can you send me your task to oleg (at) robotask.com or publish it in the forum. Maybe you have some mistakes in the task.

What do variables FILENAME_O and FILENAME_I contain? You may chek this if you put "Show Message" before running 7-zip.
Last edited by Oleg on Thu Feb 26, 2009 10:03 am, edited 1 time in total.
Oleg
Site Admin
Posts: 3202
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Issue While Using 7za.exe

Post by Oleg »

I've just wrote small example and test it. It's working.
See below:

;*******************************
;* RoboTask Task file         &n bsp;*
;* Do not edit in text editor! *
;*******************************

[Root]
ActionAfterRun=INTEGER|0
Actions=FOLDER
Automat=INTEGER|-1
CatID=INTEGER|1539658767
ContinueOnError=INTEGER|0
ExternalName=STRING|"Task753"
Hide=INTEGER|0
ID=INTEGER|1206726479
LocalVariables=STRING|"FILENAME_O,ORDNER,FILENAME_I"
LogOnAsUser=INTEGER|1
Name=STRING|"Test 7-zip commang line"
Priority=INTEGER|3
RunOnClose=INTEGER|0
RunOnStartup=INTEGER|0
ToLog=INTEGER|3
WriteGeneralLog=INTEGER|0

[Actions]
Action1=FOLDER
Action2=FOLDER
Action3=FOLDER
Action4=FOLDER

[Actions\Action1]
ActionID=STRING|"A_VARIABLES_SET"
Enabled=INTEGER|-1
Name=STRING|"Set variable ""FILENAME_O"" with value ""test"""
Params=FOLDER

[Actions\Action1\Params]
expand=STRING|"0"
varname=STRING|"FILENAME_O"
varvalue=STRING|"test"

[Actions\Action2]
ActionID=STRING|"A_VARIABLES_SET"
Enabled=INTEGER|-1
Name=STRING|"Set variable ""ORDNER"" with value ""c:\incoming"""
Params=FOLDER

[Actions\Action2\Params]
expand=STRING|"0"
varname=STRING|"ORDNER"
varvalue=STRING|"c:\incoming"

[Actions\Action3]
ActionID=STRING|"A_VARIABLES_SET"
Enabled=INTEGER|-1
Name=STRING|"Set variable ""FILENAME_I"" with value ""testeinszwei drei4.5x6"""
Params=FOLDER

[Actions\Action3\Params]
expand=STRING|"0"
varname=STRING|"FILENAME_I"
varvalue=STRING|"testeinszwei drei4.5x6"

[Actions\Action4]
ActionID=STRING|"A_GENERAL_RUN_PROG"
Enabled=INTEGER|-1
Name=STRING|"Run ""7z.exe a ""c:\dest\{FILENAME_O}.7z"" -mx9 -mhe ""{ORDNER}\{FILENAME_I}"" -p""{FILENAME_I}"""""
Params=FOLDER

[Actions\Action4\Params]
params=STRING|"a ""c:\dest\{FILENAME_O}.7z"" -mx9 -mhe ""{ORDNER}\{FILENAME_I}"" -p""{FILENAME_I}"""
program=STRING|"C:\Program Files\7-Zip\7z.exe"
runas=STRING|"0"
wait=STRING|"2"
feliciaIII
Posts: 2
Joined: Wed Feb 25, 2009 11:56 am

Issue While Using 7za.exe

Post by feliciaIII »

I finally found my mistake by trying the "showmessage" - as you suggested, it was made a few steps earlier. Now I corrected it and it works fine. thank you for your help. greets, felicia
Post Reply