2 of 2 people found this helpful
Don't use Print use Save as PDF.
Generate the needed file name and file path (to the temp folder) by using something like:
Set Variable [$Path ; Get ( TemporaryPath ) & "YourFileNameHere.PDF" ]
You can then specify $Path as the location to which you are saving the PDF in the Save as PDF step and as the path to the attached file in a Send Mail script step to send out an email to your recipients with the PDF as an attachment.
This is then fully cross platform. It'll work on both Mac and Windows systems.
Thank you so much phil. I searched but did not find the save command. I will work on it this weekend.
As a script step, it's called "save records as PDF". In the new scripts workspace you can simply type in "save" and it will appear in a menu of other matches. In the earlier versions' script editor, you can find it in the Records category.
As a Menu Option, it's in the File menu and labeled: "Save/Send Records as..." with "pdf" as an option that appears in a sub menu.
The best thing will probably be to have the PDF generated and let it be sent from a central function. From the server, with a server schedule.
Sending via email client has some important disadvantages:
- The solution will not know if the message was really sent. If the user canceled.
- When doing it from the client computer the sender (from) may not be well controlled.
- When sending from a client computer you may find that smtp or other tech. problems make the sending fail.
So you se, I find this to be create a situation with many open ends.
The easiest would be to let the server create the PDF and send the email. But here the problem is that FMS 15 can not create emails. This is one of the most "asked for" features form the community.
So: Let a client create the pdf and store it in a container field. And then let a server schedule export the pdf and send the email.
You could also have a central robot creating and sending the pdf.
Test your PDF layouts when generated on both platforms. They may need some tweaking or design two layouts, one for each platform and let the script go to layout based on Abs ( Get(systemplatform) ) = 1, go to mac layout, =2 go to windows layout