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


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


App-V

From sasCommunity
Jump to: navigation, search

Overview

App-V is a MS product: Application Virtualization. It is used to package SAS so that IT admin can provide HotFixes to the SAS installation and these will be automatically pushed to your local desktop installation.


http://www.microsoft.com/windows/enterprise/solutions/virtualization/products/app-v.aspx

keywords: appv app-v

Batch Processing

Setting up a project to use App-V launch of SAS for batch processing is non-trivial, as it requires explicit declaration of -all- startup options.

These are the files needed:

  1. sasappv.bat
  2. sasappv.cfg
  3. MyProgram.bat


sasappv.bat

This is the call to AppV to launch SAS.

C:\WINDOWS\system32\CCM\VAppLauncher.exe /launch "SAS 9.2 (English) 9.21300.19370.57" %*

Notes:

  • the string suffix (9.2.13...) may be different at your site.
  • percent-asterisk is the DOS command that means: pass all parameters to the program, in this case the SAS command line.

sasappv.cfg

Place common startup options is a configuration file.

/* name: sasappv.cfg for v9 */
-set project !folder        /*set in calling MyProgram.bat */
/* or hardcode:  *****************
-set project 'Z:\App-V\sas' /* *** */

-autoexec        '!project\autoexec.sas'
-log              !project
-print            !project
-sasinitialfolder !project

-fullstimer /* full system timer:

-nocenter   /* listing is justify=flush left
-noovp      /* reduce log size: no overprint error nor warning msgs */
-nosplash   /* save time: no SAS icon during startup */


MyProgram.bat

rem RnD-print.bat
rem 1. allocate an environment variable with the folder name
set folder=Z:\App-V\sas
rem 2. call sas with explicit program name and config file
sasappv -sysin "%folder%\RnD-print.sas" -config "%folder%\sasappv.cfg"

Notes:

  • rem is DOS remark: a comment
  • set is DOS verb to allocate an environment variable
  • sasappv refers to the above file sasappv.bat
  • -sysin all SAS command-line options must be named
  •  %folder% is DOS reference to the environment variable folder
  • -config refers to the above file: sasappv.cfg


References

--macro maven == the radical programmer 14:33, 27 July 2011 (UTC)