I have a batch command. As it follows. It can zip directories in other directory.
@echo off
set "zip=7z a -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on"
set "directory=C:\SqlData\BackUpData"
for /d %%i in ("%directory%\*") do %zip% "%%~fi.7z" "%%~fi\*"
I want to add one more line. It should delete original file after zipped. Thanks.
If I understand you correctly, I think this is the line you're looking for: