As the first step in the decommissioning of the site has been converted to read-only mode.

Here are some tips for How to share your SAS knowledge with your professional network.

SASautos Companion Reusing Macros

From sasCommunity
Jump to: navigation, search

A SASautos Companion: Reusing Macros

Ronald J. Fehd

Here is the TinyUrl for this page:

A .pdf of the paper is available here.


Reusable SAS(R) programs come in two forms: macros or %includes. This paper reviews the standard SAS environment and examines the options used to customize a session or batch program for reuse of macros stored in the project directory.

Expected audience is intermediate to advanced programmers and macro users.

Keywords: autocall compile macro masking MautoSource mStored program reuse SASautos SASmStore source store

Here are the filenames, libnames and options used for each.

filename Project  '<directory-specification>';
filename SiteMacr '<directory-specification>';
* macro autocall is list of filerefs;
options mautosource
        sasautos = (Project SiteMacr SASautos);
* macros compiled and stored in libref.SASmacr.sas7bcat;
*libname LibMacro '<directory-specification>';
*options Mstored
         SASmStore = LibMacro;


-- created by User:Rjf2 15:57, 10 May 2007 (EDT)

--Ronald_J._Fehd macro.maven == the radical programmer