Privately please so I can send him a copy of what I might share with you.
I'm taking a course in operating systems and I'm being asked to create a log file for when a few applications start and end when they are opened through their shortcuts. I passed some parameters in the shortcuts - namely the application name (%1) and the path to get to the exe file(%2) - so that a batchfile starts to run and monitors what's going on when a shortcut file is clicked. I was able to arrange for the start date to go into the log file. But I have no idea how to get the "stop" date and time.
Here's what I have so far:
rem program to record the date and time of a bunch of applications' launching and closing into a log file
rem Create the batch program containing the launch info
If not "%2"=="" echo %1 started on %date% at %time% > a:\bats\makeprom.bat
rem add the results to the log file
command /c makeprom.bat >> a:\logfiles\logjob.log
rem Run the program
So far so good. But how can I tell when the application stops?