I have written a SAS macro that imports all the excel files in a folder and it works. What I want to do next is - send the proc import logs or results for all the excel files to a single pdf. My SAS code looks like this:
%macro readxls (copyfrom=);
---
---
---
%do i=1 %to $count_files;
ods listing close;
ods pdf file='pathname\report_import.pdf';
proc import datafile="©from.\...." out=copyto.... DBMS=xlsx replace;
getnames=yes;
run;
ods pdf close;
ods listing;
%end;
%mend readxls;
For some reason, no pdf file gets generated. And the SAS log says, "NOTE: Writing ODS PDF output to DISK destination "pathname\report_import.pdf", printer "PDF"