You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Automatically email a pdf on saving the file

Hi there.


I need to create a large number of individually customised pdf's, and automatically email them to each recipient.


Currently, I create each pdf, saving each file with the recipient's email address as the filename within a specific batch folder.

I then work through the list of files, copying each file name and pasting it as the 'to' address in a new email, and then dragging the pdf file into the body of email as an attachment.

Once a batch of emails have been created, I work through them and paste a 'subject' heading and send them off.


Has anyone any ideas as to how I could automate this in some way once the pdf's have been created ?

Posted on Mar 6, 2021 12:19 AM

Reply
Question marked as Top-ranking reply

Posted on Mar 6, 2021 2:42 PM

The sending could be automated. You could write a script when a file was dropped on the script the file would be sent to the recipient.


I have various parts of this scenario written in applescript. Let me know if you want me to paste what I have.


R

8 replies

Mar 9, 2021 1:21 PM in response to Barcodelabel

There is a lot of interaction. One step at a time.


Applescript with sending an email

Send mail with attachment and signature via AppleScript in OS X · GitHub


Learn AppleScript: The Comprehensive Guide to Scripting and Automation on Mac OS X, Third Edition the book

( while dated, it's the book I use when coding.  I haven't seen a better applescript book. )


Applescript Language Guide Online View the web page

Basics of Applescript. Does a good job of covering the basics

Basics of Applescript.


Get your questions answered here:

MacScripter / AppleScript | Mac OS X



A comprehensive list of Applescript resources.

What Applescript book? - Apple Community




Robert

Mar 9, 2021 3:58 PM in response to Barcodelabel

If you're already saving the PDFs in a given folder, it should be possible to craft a Folder Action to process the rest of the workflow - grab the file, create an email, extract the recipient address from the filename and send it off.


You could also craft it as a Quick Action/Service whereby a ctrl-click on the PDF could be used to initiate the script to send an email.


Lots of options. The devil is in the details, though, so you may need to more clearly define what you want to do.

Automatically email a pdf on saving the file

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.