How to email output of scheduled tasks?

Posted by Starfish on Server Fault See other posts from Server Fault or by Starfish
Published on 2012-03-21T17:22:11Z Indexed on 2012/03/21 17:31 UTC
Read the original article Hit count: 253

On Unix systems, the scheduled task service will email any output that a scheduled task produces. If no output is produced, no email is sent. How can I do the same thing on Windows Server 2003 or 2008? Is there a way to call a batch file or executable that will run my task, capture the output, and email it only if there is output?

If you propose a PowerShell solution, please note that I only have PowerShell 1.0.

© Server Fault or respective owner

Related posts about windows-server-2008

Related posts about windows-server-2003