LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (June 2001, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Sat, 9 Jun 2001 09:32:52 -0700
Reply-To:     "Terjeson, Mark" <TerjeMW@DSHS.WA.GOV>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Terjeson, Mark" <TerjeMW@DSHS.WA.GOV>
Subject:      SASTip: Flashless SAS X command and CALL SYSTEM
Content-Type: text/plain; charset=iso-8859-1

Greetings SAS-L,

Another *excellent* benefit of a ListServe such as SAS-L.

Every once in a while each of us comes across a jewel that can be beneficial for our differing daily SAS needs.

I do a lot of background and scheduled background tasks. The SAS X command and CALL SYSTEM have always worked great, but today, a very BIG Thank You to Richard DeVenezia, showing us a method of "flashless" spawning.

As you can tell, I am pleased to come across this goodie! Thanks Richard!

filename SASCBTBL CATALOG 'work.example.winexec.source';

data _null_; file SASCBTBL; input; put _infile_; cards4; ROUTINE WinExec minarg=2 maxarg=2 stackpop=called returns=ushort module=Kernel32; arg 1 char input byaddr format=$CSTR200.; * LPCSTR lpCmdLine, // address of command line ; arg 2 num input byvalue format=pib4.; * UINT uCmdShow // window style for new application ;

* SW_HIDE 0 ; * SW_SHOWNORMAL 1 ; * SW_NORMAL 1 ; * SW_SHOWMINIMIZED 2 ; * SW_SHOWMAXIMIZED 3 ; * SW_MAXIMIZE 3 ; * SW_SHOWNOACTIVATE 4 ; * SW_SHOW 5 ; * SW_MINIMIZE 6 ; * SW_SHOWMINNOACTIVE 7 ; * SW_SHOWNA 8 ; * SW_RESTORE 9 ; * SW_SHOWDEFAULT 10 ; * SW_MAX 10 ; ;;;;

data _null_; rc = modulen ('WinExec' , 'd:\mypath\myprogram.exe' , 6); run;

Very Appreciative, Mark Terjeson Washington State Department of Social and Health Services Division of Research and Data Analysis (RDA) mailto:terjemw@dshs.wa.gov


Back to: Top of message | Previous page | Main SAS-L page