If only one instance of that program is running, the following bat file
could prove useful to you to determine the PID of that process:
---
@echo off
set PID=
for /F "tokens=2 delims=," %%A in ('tasklist /nh /fo csv /fi "imagename eq
notepad.exe"') do set PID=%%A
echo pid=%PID%
---
Note that "for...do set PID=%%A" is in the same line (the post may
wrap-around). Replace notepad.exe with the executable name of the program
for which you want to find the process id.
- Chirag
PowerShow - View multiple PowerPoint slide shows simultaneously
http://officeone.mvps.org/powershow/powershow.html