は、スクリプト怒鳴る先フォルダに電子メールを選択して添付ファイルを保存します。これらのファイルを使用してアドレス帳に追加することができます。
set Dest to ((path to desktop folder) as string) & "FMail:" -- the folder to save attached files
tell application "Mail"
activate
set ListMessage to selection -- take all emails selected
repeat with aMessage in ListMessage -- loop through each message
set AList to every mail attachment of aMessage
repeat with aFile in AList --loop through each files attached to an email
if (downloaded of aFile) then -- check if file is already downloaded
set Filepath to Dest & (name of aFile)
save aFile in Filepath as native format
end if
end repeat -- next file
end repeat -- next message
end tell
私はそれを明確にするために多くのコメントを追加しました。それをあなたのニーズに適応させることができます。
問題をここで解決しました:[link](http://stackoverflow.com/questions/39509518/add-vcard-to-contacts-with-mail-rules-and-applescript) おかげで@pbell –