Hello anda_skoda,
I think maybe there is a little confusion from my previous posts.
arguments << " x " << "-y" << " *.* " << "-o" << (destination + "/output files") << " -r";
qDebug() << "Cmd - " << cmd;
qDebug() << "Arg - " << (arguments.join(""));
Cmd - "7z"
Arg - " x -y *.* -oH:/my dir/systems/output files -r"
QStringList arguments;
QString cmd = ("7z");
arguments << " x " << "-y" << " *.* " << "-o" << (destination + "/output files") << " -r";
qDebug() << "Cmd - " << cmd;
qDebug() << "Arg - " << (arguments.join(""));
Cmd - "7z"
Arg - " x -y *.* -oH:/my dir/systems/output files -r"
To copy to clipboard, switch view to plain text mode
process->start(cmd, arguments);
Arg has to look like:-
" x -y *.* -o"H:/my dir/systems/output files" -r"
^ ^
process->start(cmd, arguments);
Arg has to look like:-
" x -y *.* -o"H:/my dir/systems/output files" -r"
^ ^
To copy to clipboard, switch view to plain text mode
Note - the extra 'quotes', these are needed by the program I'm calling.
This is the terminal commmand that works ok.
7z x -y myFile.zip *.* -o"H:/my dir/systems/output files" -r
^ ^
7z x -y myFile.zip *.* -o"H:/my dir/systems/output files" -r
^ ^
To copy to clipboard, switch view to plain text mode
What I can't work out is how to add the quotes to the arguments list.
Regards
Bookmarks