While I was just messing around with cmd I noticed something strange. When i type:
C:\Users\szymo>tasklist
In the end of results, as a process tasklist gets displayed
So thought: If it's getting displayed as a process, what will happen if I try to taskkill it. And it appears that if I do like this, i get a communicate that:
I tried to do this using PID, but also didn't work. :
Can someone explain why this happens??. Thank you in advance
CodePudding user response:
Tasklist WAS the process you ran to display the tasks. It is ended before you can kill it. So it is no longer there. You can validate it if you run tasklist twice. Then you will have different PID so it is a new process