Hey Hobbits,
What are the possible steps for converting a file in .xlsx format to .zip.
Write the file out and then use that filepath and call powershell or cmd using the Run Command tool to compress/zip it. An example of the command:
powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::CreateFromDirectory('\\server\drive\filelocation', '\\server\drive\filelocation2\Test.zip')}"
Hi @Bilbo_Baggins,
Not quite what you are asking for but,as XLSX format is already compressed, adding ".zip" to the file extension (ren %source_path% %target_file% or move %source_path% %target_path% via Run Command tool) could also be an option.
Thanks,
Paul
Or you could use a python zip library if you want to zip multiple different files into one compressed archive.