Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!cs.utexas.edu!uunet!mcsun!hp4nl!cbmnlux!cbmehq!cbmger!peterk From: peterk@cbmger.UUCP (Peter Kittel GERMANY) Newsgroups: comp.sys.amiga.programmer Subject: Re: Execute() questions Message-ID: <1088@cbmger.UUCP> Date: 9 Apr 91 11:37:20 GMT References: <2788@sirius.ucs.adelaide.edu.au> Reply-To: peterk@cbmger.UUCP (Peter Kittel GERMANY) Organization: Commodore Bueromaschinen GmbH, West Germany Lines: 23 In article <2788@sirius.ucs.adelaide.edu.au> jpotter@ucs.adelaide.edu.au (Jonathan Potter) writes: >I was wondering if anyone can give me some advice on Execute(). >Basically, my problem is this: In a Directory Utility I have written, I >want to be able to a) Run programs with no output window, b) Run programs >with output, c) if possible, Run programs with output & input, d) Run >programs asynchronously, and e) if possible, Run programs async. with output >(& input) There are told to exist very elegant ways to accomplish this by very deep digging into the system. I (being a little lazy to study all this :-) recommend the easy way: Put your command line into a temporary file in ram:, add an endcli line, and with Execute() then call a newshell con:... from tempfile Thus you can easily control the window this is running in. For the current directory, you could simply put another line with a CD before your comm. line in that tempfile. Perhaps when you issue this with run >nil: newshell..., you avoid getting two windows opened. And don't forget to clean up and delete that temp file sometimes afterwards. -- Best regards, Dr. Peter Kittel // E-Mail to \\ Only my personal opinions... Commodore Frankfurt, Germany \X/ {uunet|pyramid|rutgers}!cbmvax!cbmger!peterk