0

This question already has an answer here:

Is there a way to view or log what applications have been opening windows in my system? I have Windows 10.

My reason for wanting to do this is that I have a really annoying issue where every hour something on my system opens a command prompt window and then immediately closes it. I've scanned with Malwarebytes and it hasn't turned up anything. I've also turned on history in Task Scheduler, but no task's run time corresponds with when it happens. I'm hoping to log all the times windows are opened to figure out what is causing this.

marked as duplicate by magicandre1981 windows May 29 '17 at 16:10

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1

If you know approximately when the windows occurs, you can use process monitor. The logs will be quite massive, but if you start by adding a filter to only show cmd.exe processes and perhaps only operations that is Process Start, you might be able to filter out most noise. enter image description here

When you get a match, select it and go to Tools and Process Tree.... It should be selected on the process that popped up, and you can see what parent process started it, and with what parameters.

If you get no match, remove the Process Name filter and try again. This time, you will see all the processes on your system that starts, so it will be much more noisy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.