Following the syntax guide here: http://sevenzip.sourceforge.jp/chm/cmdline/switches/update.htm
The following code should be correct - at least it looks syntatically correct. But when I run it I get the error "incorrect command line" - meaning a syntax error. Does anyone know what is wrong with this?
I am using 7zip version 9.20.
7z u H:\archive.7z -up0q3r2x2y2z1w2!H:\update-february.7z
Try to add "endlocal" before 7z command:
endlocal
7z u H:\archive.7z -up0q3r2x2y2z1w2!H:\update-february.7z
The error was due to !
in 7z command line, when used setlocal enabledelayedexpansion