|
in a macro module, I normally test for existence of the file on a network
server:
%macro a;
%if %sysfunc(fileexist(&wfname)) %then %do;
<lots of data step and proc operations>
%mend;.
this works fine and I only included it above to illustrate it's use
now, when I want to %include (%inc) a module, it will not permit me to use
the syntax from inside another macro
for example
%macro b;
<lots of operations>
%inc <mypath>
%mend;
if the included module contains as it's 1st line
%if %sysfunc(fileexist(&wfname)) %then %do;
how else might I test for file existence in included modules?
curiously the &wfname resolves fine, as in
data a; infile &wfname ;
|