Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!uunet!mcsun!hp4nl!eurtrx!euraiv1!reino From: reino@cs.eur.nl (Reino de Boer) Newsgroups: comp.lang.pascal Subject: Re: Pascal Question Message-ID: <1989Dec1.123006.5648@cs.eur.nl> Date: 1 Dec 89 12:30:06 GMT References: <89334.082120JTW106@PSUVM.BITNET> Organization: Erasmus Universiteit Rotterdam, dept. CS (Informatica) Lines: 39 JTW106@PSUVM.BITNET (Jeff Wolfe) writes: >While using TP 5.0's EXEC command, the program seems to 'skip' over the EXEC >statement. I am using the $M compiler directive, but it still won't work. > the program: >program testEXEC; >{$M $4000,0,0} > uses DOS; >begin > exec ('Command.com',''); >end. >and Command.com *IS* in the same directory as the program for this test! >Does anyone have any Ideas? (please Email me, and I'll post a summary) I have tried the following: {$M $4000,0,0} program testEXEC; uses dos; begin exec( 'c:\command.com', '' ); if doserror <> 0 then writeln( 'DosError[', doserror, ']: something went wrong' ) end. and this works fine on my machine (that is, I get no doserrors, and I do get a command shell). Hope this helps -- Reino -- Reino R. A. de Boer Erasmus University Rotterdam ( Informatica ) e-mail: reino@cs.eur.nl