| Date: | Thu, 7 Jul 2005 13:50:12 -0700 |
| Reply-To: | "Pardee, Roy" <pardee.r@GHC.ORG> |
| Sender: | "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> |
| From: | "Pardee, Roy" <pardee.r@GHC.ORG> |
| Subject: | Re: Capturing SAS exit code (error code) using Ultraedit |
|
| Content-Type: | text/plain; charset="iso-8859-1" |
Wow--I never dreamt that sas used the return code to signify presence/absence of errors. That makes sense.
I don't know whether UE can be set up to do this. FWIW--what I do is have UE shell out to a vbscript, which actually does the submitting to sas & checks the log for warnings/errors w/a simple regex. Here's a version that displays sas' return code in the vbscript:
http://rafb.net/paste/results/YJ1z0F58.html
I launch that w/the following UE Tool command line:
wscript "C:\Documents and Settings\pardre1\My Documents\WSH\SasWrap.wsf" /sasprog:"%f"
You could edit that pretty easily to make the log check conditional on the return code (tho I don't know that I'd advocate that--there are several unsavory things sas does w/out issuing WARNINGs--type coercions, manufacturing uninitialized variables, etc.).
HTH,
-Roy
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Arnd Winter
Sent: Thursday, July 07, 2005 7:50 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Capturing SAS exit code (error code) using Ultraedit
I am trying to evaluate Ultraedit as a replacement for Textpad which we have been using as a SAS(8) editor.
So far everything works fine: Syntax highlighting, Invokation of SAS Jobs, generation of log-File and lst-File.
The only thing which does not work is capturing the SAS exit code: In textpad a window pops up indicating error (exit-) code 2 or 1 if the job terminated with an error or a warning. This is quite nice so we donīt have to check the log for errors if there are none.
So far I have not been successful to capture the exit code in Ultraedit. I have noticed (and tried) the several options in the Toolbox settings but nothing has worked so far.
Is there anyone who has a solution for this?
(In SAS-L I have found several threads concerning Ultraedit but I havenīt seen one covering exit codes)
Thanks for your help,
Arnd Winter (Pforzheim, Germany)
|