I am getting the following error trying to use the mailR package (0.4.1).
Error in send.mail(from = "EMAIL@gmail.com", to = EMAIL@gmail.com", : could not find function "send.mail
Code is listed below. Just trying to send an email with an inline image. I got the gmailR package to send an email, but could not get an inline image to show up. I would be more than happy to use either package.
library(mailR)
library(rJava)
png(file.path(getwd(), "FILEPATH.png", "img.png")); plot(0); dev.off()
send.mail(from = "EMAIL@gmail.com",
to = "EMAIL@gmail.com",
subject = "Image TEST",
body = '<img src="../img.png">',
html = TRUE,
inline = TRUE,
smtp = list(host.name = "smtp.gmail.com",
port = 465,
user.name = "EMAIL@gmail.com",
passwd = "PASSWORD",
ssl = TRUE),
authenticate = TRUE,
send = TRUE)
Please let me know if you have any questions.
Thanks.