Hi. Thanks for the time. I guess the title is a bit confusing. What I am trying to is 1) export a list to an htm file and then 2) email that htm into the body of the email. Can this be done using send-mailMessage? This is what I have below and it
works as an attachment but I want to put it the attachment into the body of the email.
get-messagetrackinglog -resultsize unlimited -recipient me@domain.com -start (get-date).adddays(-1) |select messageid -unique | measure | ft count > c:\myfolder\emails.htm
Send-MailMessage -to "me@domain.com" -subject "Daily" -smtpserver smtp -from "me@domain.com" -attachment "c:\myfolder\emails.htm"
get-messagetrackinglog -resultsize unlimited -recipient me@domain.com -start (get-date).adddays(-1) |select messageid -unique | measure | ft count > c:\myfolder\emails.htm
Send-MailMessage -to "me@domain.com" -subject "Daily" -smtpserver smtp -from "me@domain.com" -attachment "c:\myfolder\emails.htm"