知道如何在此电子邮件中添加附件吗?
我试着查看名称(OutApp)以查看是否有"附件"我可以分配,但似乎没有。有什么想法吗?
library(RDCOMClient)
SendEmail<-function(to, subject, body)
{
## init com api
OutApp <- COMCreate("Outlook.Application")
## create an email
outMail = OutApp$CreateItem(0)
## configure email parameter
outMail[["To"]] = "me@me.com"
outMail[["subject"]] = subject
outMail[["body"]] = body
## send it
outMail$Send()
}