Exporting Scheduled Tasks from Windows Task Scheduler to CSV
I stumbled across a cool tidbit of information this morning. I was attempting to export a long list of scheduled jobs from the Windows Task Scheduler, but was thinking that I’d have to either build a powershell script to do it for me, or manually export each task individually, and then aggregate all the results.
Not so! Turns out there’s a command for that.
schtasks /query /S SERVERNAME /FO CSV /V > exportedjobs.csv
This will take all scheduled tasks (including system jobs), and export them to a file named exportedjobs.csv
in your current working directory.
Then, you can import this into Excel and massage the data however you’d like.
Cool, huh?