[英]Applescript to Paste clipboard text into Messages and send to email
[英]Applescript to send an email with signature
我正在尝试使用 Apple 脚本发送 email。 一切正常,即使 email 被发送到脚本中使用的地址。 我的问题是我无法在 email 内容中添加签名。 这是代码
tell application "Mail"
set theSubject to "Subject if the testing email" -- the subject
set theContent to "Body of the email goes here" -- the content
set theAddress to "test123@gmail.com" -- the receiver address
set theSignatureName to "Charu" -- the signature name
set msg to make new outgoing message with properties {subject:theSubject, content:theContent, visible:true}
tell msg to make new to recipient at end of every to recipient with properties {address:theAddress}
set message signature of msg to signature theSignatureName
send msg
end tell
当我尝试运行此程序时,我收到一条错误警报,提示Mail got an error: AppleEvent handler failed.
我不确定如何设置签名。
提前致谢
回顾以前的线程(比如这个),似乎在 High Sierra 及更高版本中,使用message signature
添加签名不再起作用。 你最好的选择是只 append 你对theContent
的签名。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.