Skip to content

CheckLog Scripts

Chris Swenson edited this page Nov 15, 2020 · 2 revisions

The following scripts extend SAS and work with some of the macros available on this site.

Descriptions

  • CheckLog.vbs
    • Runs CheckLog from a Windows icon and asks the user which file to check.
  • CheckLogSendTo.vbs
    • Runs CheckLog from a Windows context menu, using the active file or directory. Additionally, it asks the user if any additional arguments are desired.
  • LaunchSAS.txt
    • Launches SAS with a custom Windows title, useful for launching multiple SAS sessions named by project, process, or some other identifier.
    • This one requires the user to change the extension from "txt" to "vbs".

Note: All of these files require VBScript (Visual Basic Script). VBScript is available for Linux via Mono. The instructions below are Windows-based and will require changes for other operating systems.

Instructions

CheckLog Scripts

  1. Download the CheckLog SAS macro and save it to a permanent location.
  2. Download the CheckLog.txt and/or CheckLogSendTo.txt files.
  3. Open each file and replace the value of the variable CheckLog with the location of the CheckLog SAS macro.
  4. Save each file.
  5. Change the extension of each file to "vbs".
  6. For CheckLog, launch the script and specify the file to check.
  7. For CheckLogSendTo, continue with the following instructions.

CheckLogSendTo

  1. Create a shortcut for the CheckLogSendTo.vbs file. Rename it as "CheckLog".
  2. Copy the shortcut to the user's SendTo files here: C:\Documents and Settings%USERNAME%\SendTo, replacing the %USERNAME% variable with the username in question.
  3. Right click on a file or directory to check. Go to Send To > CheckLog.
  4. Select Yes (Add arguments), No (Use the default arguments), or Cancel (Cancel the check) when asked whether you would like to add additional arguments.
  5. If you said Yes above, enter the additional arguments you would like to use. See the Arguments page for more detail.

LaunchSAS

  1. Download the LaunchSAS.txt file.
  2. Open the file and replace the value of the variable Config with the location of the configuration file.
  3. Save the file.
  4. Change the extension to "vbs".
  5. Launch the script and specify the name of the SAS session you want to use.