Select Page

Send a Simple Email 

Send-MailMessage -To “User01 <user01@example.com>” -From “User02 <user02@example.com>” -Subject “Test mail”

Send an email with attachment

Send-MailMessage -From “User01 <user01@example.com>” -To “User02 <user02@example.com>”, “User03 <user03@example.com>” -Subject “Sending the Attachment” -Body “Forgot to send the attachment. Sending now.” -Attachments “data.csv” -Priority High -dno onSuccess, onFailure -SmtpServer “smtp.fabrikam.com”

Send an email to a mailing list

Send-MailMessage -To “User01 <user01@example.com>” -From “ITGroup <itdept@example.com>” -Cc “User02 <user02@example.com>” -bcc “ITMgr <itmgr@example.com>” -Subject “Don’t forget today’s meeting!” -Credential domain01\admin01 -UseSsl