Here's a little piece of code that I jiffied up a few years ago. You might find it to be useful.
Tom
/* Put your EG project and the directory pointing to it in these two variables */
%let ProcessDir = C:\ddd;
%let DSN = project.egp;
/* Get code from a zip file member */
%macro GetZipCode(ProcessDir, DSN, ZIPMember, SASMember);
filename inzip zip "&ProcessDir.\&DSN." member="&ZIPMember.";
data _null_;
infile inzip;
file "&ProcessDir.\&SASMember.";
input;
put _infile_;
run;
%mend; /* GetZipCode */
/* Assign a fileref wth the ZIP method */
filename inzip zip "&ProcessDir.\&DSN.";
/* Read the "members" (files) from the ZIP file */
data _null_;
length memname $200;
fid=dopen("inzip");
if fid=0 then
abort;
memcount=dnum(fid);
do i=1 to memcount;
memname=dread(fid,i);
if scan(memname, 2, "/") = "code.sas"
then call execute("%"||"GetZipCode(&ProcessDir., &DSN., "||trim(left(memname))||", "||trim(left(scan(memname, 1, "/")))||".sas);");
end;
rc=dclose(fid);
run;
... View more