From: sannak on
Hi ,

I want to invoke .exe file using SAS program, could someone please give
me alternatives to X-Command or Call system commands.

When I use X-Command or Call system command I'm getting the following
errors.

Error when I use call system command is :

WARNING: Shell escape is not valid in this SAS session.

Error when I use call X command is :

I'm invoking these commands in SAS from UI which is developed in .NET.

Thanks in advance.

-KS

From: Richard A. DeVenezia on
sannak(a)gmail.com wrote:
> Hi ,
>
> I want to invoke .exe file using SAS program, could someone please
> give me alternatives to X-Command or Call system commands.
>
> When I use X-Command or Call system command I'm getting the following
> errors.
>
> Error when I use call system command is :
>
> WARNING: Shell escape is not valid in this SAS session.
>
> Error when I use call X command is :
>
> I'm invoking these commands in SAS from UI which is developed in .NET.

The SAS session being invoked/utilized from your .NET UI is being started
with the -NOXCMD system option in the config.sas or command line. The
option cannot be changed after a session has been started.

Your most 'secure' way of obtain shell escape is to petition the powers that
be which control the SAS invocation and state your case on why the SAS
session should be allowed to shell escape. Your app may require a change in
Integration Technologies configurations -- such as a special login for only
your app, whose account causes a customized config.sys or command line to be
used to start the SAS session that your app will use. Another might be to
start a SAS service that has shell escape, but the service requires extra
authentication to use.

--
Richard A. DeVenezia
http://www.devenezia.com/


From: David L Cassell on
sannak(a)GMAIL.COM wrote:
>
>Hi ,
>
>I want to invoke .exe file using SAS program, could someone please give
>me alternatives to X-Command or Call system commands.
>
>When I use X-Command or Call system command I'm getting the following
>errors.
>
> Error when I use call system command is :
>
>WARNING: Shell escape is not valid in this SAS session.
>
> Error when I use call X command is :
>
>I'm invoking these commands in SAS from UI which is developed in .NET.
>
>Thanks in advance.
>
>-KS

If your SAS session is invoked - either implicitly or explicitly - with the
NOXCMD option, then you are not going to be allowed to shell out
to a child environment. It will not matter whether you use the
X command or SYSTASK() or CALL SYSTEM().

So you need to do two things.

[1] Meet with the sysadmins and the U designer to see if this can be
changed.

[2] Consider whether your .exe file even needs to be run from SAS.
Perhaps SAS could do all the work of the .exe file so you could skip
the shell-out part of your process. Perhaps SAS could be run from a
'glue' program which would let the .exe program run in another instance
of the OS without needing to shell out from SAS to do it.

HTH,
David
--
David L. Cassell
mathematical statistician
Design Pathways
3115 NW Norwood Pl.
Corvallis OR 97330

_________________________________________________________________
Don?t just search. Find. Check out the new MSN Search!
http://search.msn.click-url.com/go/onm00200636ave/direct/01/