Hi,
Your request is pretty old but this might help some other reader.
Did you mean something like this, where the content of the macro is saved in another file?
%macro demo (memname=);
%put Message in the log;*won't appear in the new file;
title 'This is a demo';
proc print data=sashelp.&memname.;
run;
%mend demo;
options mfile mprint ;
filename mprint "&xxproject./pgms/new.sas ";
%demo(memname=class);
... View more