send me an email when your done executing a script ...
can't get this script to email me ... any suggestions ?? # when done, send us an email with the log text $SmtpClient = new-object system.net.mail.smtpClient $MailMessage = New-Object system.net.mail.mailmessage $SmtpClient.Host = "mailboxserver" $mailmessage.from = ("user@domain.com") $mailmessage.To.add = ("user@domain.com") $mailmessage.Subject = “script.ps1 script has completed” $mailmessage.Body = $EmailBody $smtpclient.Send($mailmessage)
March 31st, 2010 12:53am

Try using a hub transport server instead of a mailbox server for your smtp host.
Free Windows Admin Tool Kit Click here and download it now
March 31st, 2010 1:03am

ill give it a try .. thanks
March 31st, 2010 1:07am

that did the trick thanks.
Free Windows Admin Tool Kit Click here and download it now
March 31st, 2010 9:27pm

Cool. Mailbox servers don't "do" smtp relay. They pretty much won't talk to anything but a hub transport server.
March 31st, 2010 10:00pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics