2 Replies Latest reply on Jul 5, 2016 1:48 PM by mikebeargie

    How to script printing of multiple layouts plus multi page PDFs in containers in sequence.

    AnthonyTesoriero

      Title

      How to script printing of multiple layouts plus multi page PDFs in containers in sequence.

      Post

           I need some scripting written for a filemaker solution.
            
           We need a script that will print a multipage PDF within a printing sequence.
            
           Knowing your familiarity with filemaker PRO, you know that filemaker is unable to print multipage PDF's in container fields. Further complicating the mater filemaker pro for mac has a frequent problem crashing on larger files when using Adobe as the default web plugin to view PDF files, thereby making it necessary to default to using "preview" for mac as the default reader. The problem with using preview though is that when certain documents were created originally using acrobat such as forms or PDFs with embedded pics, Preview will fail to recognize the data on the forms or the embedded pics thereby rendering a blank page, making its necessary to use Acrobat only to print the documents...
            
           Our solution requires us to batch print large amounts of documents from found sets within our database.
            
           Each record has a series of layouts that must be printed in a specific order and a collection of attachments (container fields) that must also be printed.
            
           Currently we are able to batch print all the filemaker layout documents in the proper sequential order for a batch, (Average 20 records per batch, each record having 10 pages = 200 Pages (without corresponding attachments) 
            
            Because of filemaker's limitations however we must then manually go into each record, open each relevant attachment, right click to "open as" Adobe PDF, execute a print command, manually close the adobe window, manually close the filemaker container window and repeat for each relevant attachment per record.... As you can imagine this becomes very time consuming. 
            
           To make matters more complicated we then have to hand collate the documents to insert the separately printed container PDF's and associate them with the other printed docs...
            
           Ideally we would like a cross platform solution that will enable us to print the entire file in the proper sequential order so that it is pre collated.  (i.e. Print 5 layouts, print container 1, print 3 layouts, print container 2, print 2 layouts, print containers 3 and 4) move to next record repeat...
            
           However if a cross platform solution is not possible we would opt for a MAC only solution.
            
           Any assistance you can provide is appreciated.

        • 1. Re: How to script printing of multiple layouts plus multi page PDFs in containers in sequence.
          ltolan

          Just a quick thought because I don't have time to work up a test...

           

          I had a problem where I have to print asymmetricly formatted PDF documents containing text and tables.  What I did was create a container for each component and print the contents of the component as a PDF into the appropriate container.  I then have a higher level layout that has each of these container fields located where we require them.

           

          I don't know how this will work if you have variable size PDF's embedded.  Our contents of the container fields are all fixed sizes.  Playing with sliding may or may not help.

           

          Anyway...  Just a hint...  Good Luck

          • 2. Re: How to script printing of multiple layouts plus multi page PDFs in containers in sequence.
            mikebeargie
            Because of filemaker's limitations however we must then manually go into each record, open each relevant attachment, right click to "open as" Adobe PDF, execute a print command, manually close the adobe window, manually close the filemaker container window and repeat for each relevant attachment per record.... As you can imagine this becomes very time consuming.

             

            This may be because of your limitations more than FileMaker's.

             

            What you may want to do is think "outside of filemaker". Is there a way to export that PDF to a temporary location, then use Send Event or AppleScript to open and print the document? Is there a way you could use a free plugin like ScriptMaster to write some Java to do that as well?

             

            Is there a paid plugin like MBS or Scribe that can merge multiple PDF documents together and then export and open a combined PDF for printing?

             

            There is a lot filemaker can do if you think outside of the box!