Hi MT,
I think this will do what you need:
http://msdn.microsoft.com/library/de...ateprocess.asp
--
Regards,
Jake Marx
MS MVP - Excel
www.longhead.com
[please keep replies in the newsgroup - email address unmonitored]
Taf wrote:
I am using the VBA Shell function, available in Excel, to run a DOS
Batch file.
Previous posts have shown me how to make Excel wait for the batch file
to comlete by using the Windows API and monitoring for the status of
the Process ID.
There are circumstances where I would like to kill the batch file
before it is completed. (Timeout or uer interupt for instance)
Is there a way to get Excel to kill the a previosly 'shelled' process
without having to wait for it to complete normally?
Many thanks
MT