TZipper query lazarus / 62-General ---------------------------------------------------------------------- AMJF · 2022-05-27 04:20 In my program, I'm using TZipper to generate zip files with contents I add to the files. When I first used it, I simply adapted example code, but I notice that TZipper needs a declaration of the filename when initialised, like this example in my program: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i ZIPFIL.FileName:=TPATH+'\Test.zip';  But then later on, when it comes to saving the TZipper file, this line is used: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i ZIPFIL.SaveToFile(TPATH+'\Test.zip');  If the filename is stated in .SaveToFile, does it really need to be also stated in .FileName too? Or can I omit the .FileName? ---------------------------------------------------------------------- GAN · 2022-05-27 05:19 Use FileName to read a .zip file and use SaveToFile to create a .zip. https://www.freepascal.org/docs-html/fcl/zipper/tzipper.html https://www.freepascal.org/docs-html/fcl/zipper/tzipper.filename.html https://www.freepascal.org/docs- html/fcl/zipper/tzipper.savetofile.html