I am using macro to zip all files in a folder. When i open the zip file, date of modified becomes the date I ran the macro. When I create zip files manually, date of modified preserves original files date. Here is the code I am using. How can i preserve the original modified date in zip file?
ods package(newzip) open nopf;
%do j = 1 %to &cnt;
ods package(newzip) add file="&dir.&&name&j" mimetype="application/x-compress";
ods package(newzip) publish archive properties(archive_name="&zipnme..zip" archive_path="&ziploc");
%end;
ods package(newzip) close;
Retaining timestamps for ZIP files has been discussed before on SAS Communities:
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.