|
A stored process is a SAS program that is saved on a server and can be
executed as required by a requesting application. After saving a SAS program,
you can invoke it from ArcMap using a VBA (Visual Basic for Applications)
macro that you define in and run from ArcMap.
To access a SAS stored process from ArcMap:
Define a SAS program:
- Select File
New Program from the SAS menubar.
- Write your program. You can encapsulate any SAS data step or macro
code in a stored process.
- Save the program. By default, the file extension is .sas.
If you use this default extension, then you do not need to specify it
in your ArcMap VBA macro.
Define a VBA macro in ArcMap:
- Select Tools
Macros
Visual Basic Editor from the ArcMap menubar.
- Select Tools
References from the menubar of the Visual Basic Editor.
- Select the following from the References
window:
- SAS Integrated Object Model (IOM) Type Library
- SAS WorkspaceManager 1.1 Type Library
- Select Insert
Module from the menubar of the Visual Basic Editor.
- Type the macro code. Click here
for a sample.
Run the macro:
- Select Tools
Macros
Macros from the ArcMap menubar.
- Select the macro you want to run.
- Click Run.
For additional information on SAS stored processes, see these resources:
Demos and Downloads
|