Timeline for How to find process pid of an application
Current License: CC BY-SA 3.0
14 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
May 8, 2015 at 18:40 | vote | accept | CommunityBot | ||
Apr 29, 2015 at 17:55 | history | edited | Karan | CC BY-SA 3.0 |
goto not required
|
Apr 27, 2015 at 5:56 | comment | added | Karan | @Scott: That does seem to be the case. If there's any chance at all that it will return the PIDs in random order, the code can be altered to take each PID from pidlstold and delete it from pidlstnew till only one is left. So far I don't think that's required. | |
Apr 27, 2015 at 5:27 | comment | added | Scott - Слава Україні |
@Karan: Ah, basically a streamlined version of what I suggested in my comment. How do we know that tasklist will list processes in order of creation?
|
|
Apr 27, 2015 at 4:58 | comment | added | Karan | @Scott: Meh, let's ignore for the moment what the OP knows or doesn't know about taskkill. :) Going by his latest comment though I do seem to have figured out what he wants, hence my edit above. | |
Apr 27, 2015 at 4:56 | history | edited | Karan | CC BY-SA 3.0 |
added 1087 characters in body
|
Apr 27, 2015 at 0:41 | comment | added | Scott - Слава Україні |
@Karan: I agree that it’s an XY problem, but I think you’ve got the X wrong. I think X is, “If a.bat says (as a hypothetical, illustrative example) start calc , how can it later terminate the calc process that it started, given that b.bat and c.bat have also started their own instances of calc (and that we don’t want to kill them)?” (Or something like that.) (Y is, “How can a.bat assign a pid of 1001 to its calc , so it can later kill its calc process by using that pid?” That suggests that the OP does know how to taskkill /pid .)
|
|
Apr 25, 2015 at 21:19 | comment | added | Karan |
"The OP did mention he knows how to taskkill /pid " - No, he did not. Read the question carefully again. He says he's trying to kill by using the process name, and that "I want to kill just the specific one by providing the pid of that process." So clearly he doesn't know how.
|
|
Apr 25, 2015 at 21:18 | comment | added | Felype |
Indeed. I just said what I think it might be. The OP did mention he knows how to taskkill /pid , so this answer doesn't answer at all, even if the question may sound stupid.
|
|
Apr 25, 2015 at 21:16 | comment | added | Karan | @Felype: I'm not accusing you of being the downvoter. All I'm saying is that clearly the OP's on the wrong track and my answer is relevant, so the downvote is IMO stupid unless the voter can give me a good reason for it. | |
Apr 25, 2015 at 21:15 | comment | added | Felype | Yes I understand, present him the other filters, he clearly stated to know how to kill by PID, present now the /f method to filter by imagename, window name, etc. Again, I didn't downvote. | |
Apr 25, 2015 at 21:14 | comment | added | Karan | @Felype: Read my answer. It's an X-Y question. The OP is trying to kill using the process name, but doesn't need to since taskkill can already kill using specific PIDs. What he wants to do (change PIDs) is useless for the purpose of killing instances since they already have different PIDs by his own admission. | |
Apr 25, 2015 at 21:12 | comment | added | Felype | I'm not the one to downvote, but that answer seems a bit off the question. The question was: "How to change the PID of a process". | |
Apr 25, 2015 at 21:08 | history | answered | Karan | CC BY-SA 3.0 |