JDJ> I am having trouble getting the EXEC command to work in Turbo Pascal v5.0
JDJ> on the PC. Here is an example program:
JDJ> PROGRAM TEST;
JDJ> USES DOS;
JDJ> BEGIN
JDJ> EXEC('dir','');
JDJ> WRITELN('DONE')
JDJ> END.
Have you considered assigning a little memory for the program you are calling to work with :-) Try something like {$M 1024,0,0} in the first line... You might have to fiddle a bit to get the numbers to an optimum but that's basically what the problem is.