batch files 
Author Message
 batch files

when i call a batch file from a Pascal program, does the program wait for
the batch process to finish before it carries on with the rest of the
program, or does it continue with the program, as the batch file is being
processed by the operating system? i imagine that it has to wait for the
batch program to be completed before it can carry on, as turbo pascal,
version 5.5 is what im using, runs through msdos, which is not capeable of
running two processes simultaneously? im not 100% sure, and with my a-level
project coming up soon, i would like to know, as i will be running a backup
utility with a batch file.

thank you very much

craig hennessey

http://www.*-*-*.com/

please take a visit to my website if you have time. comments are welcomed,
if constructive.



Tue, 15 Apr 2003 03:09:32 GMT  
 batch files


Quote:
> when i call a batch file from a pascal program, does the program wait for
> the batch process to finish before it carries on with the rest of the
> program, or does it continue with the program, as the batch file is being
> processed by the operating system? i imagine that it has to wait for the
> batch program to be completed before it can carry on, as turbo pascal,
> version 5.5 is what im using, runs through msdos, which is not capeable of
> running two processes simultaneously? im not 100% sure, and with my
a-level
> project coming up soon, i would like to know, as i will be running a
backup
> utility with a batch file.

you're absolutely right, the program will have to wait for the batch file,
although there some tricky possibilities to go around this, but I don't
think you really want to use them....

Martin
--

Homepage: http://DarkSpix.home.pages.de/



Tue, 15 Apr 2003 04:39:35 GMT  
 batch files
With pure, plain old MS-DOS: no - unless you install
some tasking extension. But on multitasking OSes, you can do it easily:

- Win 9x: you call "start.exe mybatch.bat" via "command.com" or directly
- DR-DOS: you call "taskmgr /c mybatch.bat" instead of "command.com".

So your program continues, while 'mybatch.bat' is running.

HTH

______________________________________________________
Gautier  --  http://members.xoom.com/gdemont/gsoft.htm



Tue, 15 Apr 2003 04:57:49 GMT  
 batch files

Quote:

> when i call a batch file from a pascal program, does the program wait for
> the batch process to finish before it carries on with the rest of the
> program, or does it continue with the program, as the batch file is being
> processed by the operating system? i imagine that it has to wait for the
> batch program to be completed before it can carry on, as turbo pascal,
> version 5.5 is what im using, runs through msdos, which is not capeable of
> running two processes simultaneously? im not 100% sure, and with my a-level
> project coming up soon, i would like to know, as i will be running a backup
> utility with a batch file.

I imagine it would wait for the batch file - but that may not be sufficient;
it depends on what the batch file does. In particular, does it load any TSRs
that may take some time to complete?

I've had similar problems before trying to execute a sequence of TSRs (I
have a program that can run either normally or as a TSR; if normally, I can
chain several invocations together and when one finishes the next is called.
If I invoke them in TSR mode this doesn't work, because the second is called
as soon as the first finishes loading into memory.)

At any rate, why don't you just try it and find out?

--
______________________________________________________________________
     The Scarlet Manuka,      |        Nitpickers' Party motto:
  Pratchett Quoter At Large,  |  "He who guards his lips guards his
 First Prophet of Bonni, is:  |  soul, but he who speaks rashly will

______________________________|_______________________________________



Tue, 15 Apr 2003 16:01:36 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Executing DOS batch files (or any other program files) and deleting files with PASCAL

2. how to use exec for batch files

3. Executing batch files.

4. Batch files and the mouse

5. please help - create a batch file to create folders

6. Batch Files

7. Try to execute a batch file with WINDOWS98 that use COM1

8. Can you Exec() a batch file?

9. Batch File

10. Using Pascal to run batch files

11. Running batch file with exec

12. How do I run a batch file in TP 6 using EXEC

 

 
Powered by phpBB® Forum Software