Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

create invoices and mail as attachments to found set


This topic is 6631 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I'm trying to make a database that can print invoices as PDF's and send them via email...

the Print script step seems to do what i want if i use a loop and perform w/out dialog, specifying "Mail PDF" as the print options.

this generates seperate emails, each with it's own invoice attached.

the only problem is that it doesn't give any options for setting the email address based on a field!!

I tried using automator and added the "extract field data" step before the new mail step, but it puts the email address in the body of the text instead of the TO field, and i cant figure out anyway to change that.

anyone have any ideas???

Posted

Why aren't you using the standard Save As PDF script step? This allows attachment to e-mail directly as well as specification of email address / content.. or maybe i just automated it, i forget - but it's easy to automate.

Posted (edited)

I was originally, but im printing out multiple invoices to PDF...everytime the script loops it overwrites the pdf file with a new one and i end up with a bunch of emails that are addressed correctly, but all have the same attachment...

am i missing something about the way this works?

Ummm...Nevermind, I've been working too hard today...

I went through the script again and using print to pdf seems to be working now...I guess it's just time for a break :

Edited by Guest
Posted

Yep, use variables and something akin to the following script:

Loop

SetVariable[$name ; yournamehere]

SaveRecordsAsPDF[i forget this syntax - but the emaily bit goes here, - without dialog]

Go To Record[next ; exit after last]

End Loop

Posted

The syntax for the Set Variable and/or Save Record as PDF (depending on how you implement the solution) is quite a bit more complicated than what you show, Genx. You need to specify a path somehow, not just the name of the file. The complete path needs to be specified in the variable and the variable referenced in the Save Records as PDF options OR the name can be specified in the variable and placed at the end of a path in the Save Records as PDF step. There is an example of how to do this on my web site:

http://www.filemakerpros.com/SAVEDYN.zip

  • 2 months later...
Posted

Hi,

Sorry for the 'late posting'. I've just been wrestling with the same problem. I've just posted the workaround that seems to work for me to the PDF section of this forum. In essence, in a loop I defined a temporary variable to name the current pdf in a [save Records as PDF] line. Then I used the [send Mail] script to send the message to an email address from the DB, add a Subject and a Message, then used the temporary address in the Attach File dialog box.

best wishes,

Peter Mayer

This topic is 6631 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.