4 Replies Latest reply on Feb 18, 2014 3:07 PM by LesliePatrick

    Inserting PDF/DOC files in fmp 12 server

    LesliePatrick

      Title

      Inserting PDF/DOC files in fmp 12 server

      Your post

           I have created a database in fmp 12 advanced which inserts PDF file references into the database, however this does not function when hosted on a host server.

            

           Can anyone help and provide a method to achieve this.

           Thanks

           Les Patrick

            

            

        • 1. Re: Inserting PDF/DOC files in fmp 12 server
          philmodjunk

               And how does it insert the PDF file references? (there is more than one way to do this.)

               Are you trying to use a server scheduled script or from a FileMaker Client of the hosted file?

          • 2. Re: Inserting PDF/DOC files in fmp 12 server
            LesliePatrick

                 Hi Phil,

                 The query was posted because the database has been developed using fmp 12 advanced.  I thought I could run the db on a hosted server, assuming full functionality would be there.  When I tried to embed a reference to a pdf I was not able to view the file from another computer.

                 I have attached my script which was written to auto generate an e-mail, complete with attachment.

                 Thanks for your help

            • 3. Re: Inserting PDF/DOC files in fmp 12 server
              philmodjunk

                   Yes, but there are two ways you might run that script: Server Side (from a server schedule) and Client Side (from a copy of FIleMaker Pro that has opened the hosted file). Which method are you attempting to use?

                   Many of the steps in your script are not server compatible. That means you cannot use a server schedule to perform this script.

                   But you can run the script from a FileMaker Pro client of the server.

                   But when I review that script it does not insert any new data into the database. It saves a PDF, but there is no script step to insert it into a container field so that other users can find and view the PDF.

                   Inserting a file "by reference" will be an issue from a FileMaker Client. Inserting it "by reference" leaves the file where it was placed--and if this is a file on the client computer, it is unlikely to be accessible by other users. You can use external storage and NOT use "By reference" when inserting the file or you can use insert by reference with a script that then uses Export Field contents to export the file to a shared directory on the server and then Re-inserts the file from the shared directory. As long as all client computers map/mount the shared directory the same way--and such that the file path created in the container field is a valid path to the file, then the file will be accessible to each client.

              • 4. Re: Inserting PDF/DOC files in fmp 12 server
                LesliePatrick

                     Phil,I thought I had copied all the script.  Attached is the remaining steps which insert the pdf into a container field.

                     You have identified the problem exactly. I am trying to run the script from the client side, I will try your suggestion of using external storage.

                     Thanks for your help

                     Les