I use a macro from Frank DiIorio, CodeCrafters, Inc. that rely on SAS Dictionary Tables: %macro source_code/store; %global source_code; proc sql noprint; select XPath into :Source_Code separated by ' ' from dictionary.extfiles where fileref like "#LN00006" ; quit; %mend; The store is optional since I like to store compiled macros in a single location and call in with a mstored and sasmstore= options. I just add the following to my code to get a footnote indicating the full path and name of code submitted: %source_code; footnote1 "SOURCE CODE: &source_code"; >On Wed, 11 Apr 2007 07:43:50 -0700, Alok <alok.rustagi@GMAIL.COM> wrote: > >>Hi all, >> >>I am facing a problem in which I need to get the location/path of a >>SAS code in a macro variable. I need to use the macro variable in the >>same SAS code. Is there any SAS option available which can do this for >>me? Or is there a code snippet which can achieve the same purpose? >> >>Can you please help me out as soon as possible since I need to deliver >>this tomorrow. Any help will be greatly appreciated. >> >> >>Thanks, >>Alok