Answer the question
In order to leave comments, you need to log in
Windows. How to get the PID of the last running process in a script?
Entry conditions.
1. Windows, starting with XP (if XP is a big problem, then you can do without it)
2. You can use only the tools built into the OS
3. You can use any script host, not only cmd.exe
Task.
There is a bat file like
@echo off
rem Этот файл может запускаться от имени ста пользователей одновременно
start /B notepad.exe rem Способ вызова notepad.exe можно изменить на любой другой, лишь бы работало
rem В этой строчке нужно узнать PID только что запущенного notepad.exe
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question