I have a PHP script which runs via Windows Task Scheduler. When it starts it automatically opens a console window where the script writes status messages. If I click on this window it stops the script running. The window is still opened but it seems the script does not work. The window does not disappear. I don't understand why it happens. How can I see any errors from the script or what it is doing.
The Windows 10 command prompt pauses when you click so that you can copy and paste text without that text changing or moving. You can escape this copy mode by simply right clicking in the console window.
Whether or not this will pause the commands running in the command prompt depends on the commands you're running. Generally it seems that commands writing output to the console will pause, whereas commands writing output to a log file will not.
To stop the command prompt from pausing:
- Right click on the title bar at the top of the console window.
Click the Options tab.
Uncheck Quick Edit Mode.
Once you've made this change, you can no longer easily copy from the console. In order to copy you will need to: