8 Replies Latest reply on May 4, 2014 4:59 PM by jared944

    Save file as PDF, error 800, "...could not be created on this disk..."

    jared944

      Title

      Save file as PDF, error 800, "...could not be created on this disk..."

      Post

           Hello everyone,

           I have a script to send my clients an email receipt. Part of the script step is saving the PDF in  the temp folder :

           Set Variable [$PATH; Value:Case (Abs(Get(SystemPlatform)) = 1; "filemac"; "filewin")&":" & Get(TemporaryPath) & Substitute ( Substitute ( Get (CurrentTimeStamp) ; "/" ; "-" )  ; ":" ; "-") & " Email Record.pdf"]

           Save records as PDF [Restore; No dialog; "$PATH" ; Records Being Browsed]
            

           This saves the file in the format “MM-DD-YYYY HH-MM-SS PM Email Record.pdf”

           The script works great the first or second time it is used after opening up the database. Then it will give me the 800 error

           “4-13-2014 4-16-57 PM Email Record.pdf” could not be created on this disk.  Use a different name, make more room on the disk, unlock it or use a different disk.

           Im not sure if it a permissions issue or a problem with filemaker. I think the script is sound since it works a few times before giving me the 800 error. Any ideas would be greatly appreciated!

           Jared

            

        • 1. Re: Save file as PDF, error 800, "...could not be created on this disk..."
          philmodjunk

               I would simplify your file path calculation by using "file:" in place of the filemac: and filewin: tags, but that is clearly not the issue here. That error message should also show the value of the $path variable. What is shown when you get that message?

               And as a test, you might replace Get ( TemporaryPath ) with get ( DesktopPath ) to see if it makes any difference and so that you can compare the file names of existing files to the file path shown in the error dialog.

          • 2. Re: Save file as PDF, error 800, "...could not be created on this disk..."
            jared944

                 Phil -

                 It doesn't matter where I put the file (the temp folder v/s the desktop), after a few attempts at running the script I get the error :

                 “4-15-2014 10-18-29 PM Email Record.pdf” could not be created on this disk.  Use a different name, make more room on the disk, unlock it or use a different disk.

                 If I close down and start the database again the problem resolves itself, until it starts throwing the same error all over again. I even ran the script on a new database file and got the same results.

                 Thanks,

                 Jared

                  

                  

            • 3. Re: Save file as PDF, error 800, "...could not be created on this disk..."
              philmodjunk
                   

                        ....and so that you can compare the file names of existing files to the file path shown in the error dialog.

                   Specifying the desktop was a test so that you could easily see what folders are being created. At the time that you got this message, you should have checked to see what files were on your desktop to see if there was already a file named 4-15-2014 10-18-29 PM Email Record.pdf on your desktop. While that seems unlikely here, it would be consistent with the error message that you are getting.

              • 4. Re: Save file as PDF, error 800, "...could not be created on this disk..."
                jared944

                     Yeah, that was my thought too. That's the initial reason I added the timestamp to the end of the filename, to make sure there wasnt any like filenames in the directory.

                     I'm thinking it must be some problem with FM, since I can recreate the problem on a totally different database. I just wanted to run it by some experts before I ask support.

                     Thanks Phil!

                • 5. Re: Save file as PDF, error 800, "...could not be created on this disk..."
                  RickWhitelaw

                       $Path seems ok, but this error message almost always has something to do with the file name. Perhaps evaluate $Path in the Data Viewer to be certain there are no illegal characters in the result.

                  • 6. Re: Save file as PDF, error 800, "...could not be created on this disk..."
                    philmodjunk

                         And such an illegal character might not be visible in the error dialogue, but I didn't see any such possibility in your script.

                         And I've used this method myself for generating a series of PDF's for attaching to email and did not encounter any such error message...

                    • 7. Re: Save file as PDF, error 800, "...could not be created on this disk..."
                      tweller860

                           Good morning, Jared.

                           Following our system upgrade to FileMaker 13 two weeks ago, I experienced the exact situation that you describe in your original post.  

                           We are using a "robot" machine to generate a PDF version of the packing slip that is then emailed to the customer so they know which order they are about to receive.  The PDF version of each packing slip is saved to the Temp folder and then attached to an email.  The file name is calculated in a local variable and uses the "Save Records as PDF" script step.  In my case hover, the file name is a little simple since we just use the packing slip number as the file name.  (This robot also generates a set of nightly inventory reports that are saved to a Desktop folder and emailed to the sales staff.  I saw the same issue when attempting to write the file to the Desktop.)  If I ran the scripts on the robot, I received the Error 800 message as you described but if I ran the scripts from my laptop, everything executed without issue.

                           Not sure what your OS is, but the robot is a Mac mini, upgraded from Mac OSX 10.7 to Mac OSX 10.9.2 and running FMPA 13.0v2.  Assuming it was a permissions issue, I ran Disk Utility to repair those permissions.  Following this operation, the first PDF would generate successfully and the email was sent, but if the system was processing a batch of packing slips, the second email would fail.

                           Since my laptop is a new MacBook Pro that came with Mavericks installed, we then attempted the extreme repair.  We wiped the hard drive on the Mac mini and installed Mavericks as if it were a new computer.  We then ran all updates and re-installed FMPA and the two plug-ins we use.  Since taking this step on Monday (4/21), I have not seen Error 800 yet.  The system has sent close 100 packing slips emails and three batches of the 15 nightly reports.

                           Since the computer is a robot, we didn't have be concerned about any other software on the machine so re-installing the OS was not an issue.  I don't know if you have this luxury or not, but I wanted to let you know what I experienced.  I hope you find this helpful.

                           Best regards,

                           TW

                      • 8. Re: Save file as PDF, error 800, "...could not be created on this disk..."
                        jared944

                             Thanks for the info, Todd.

                             It seems to be ~really~ sporadic now. I honestly haven't been able to reproduce the error all week. Maybe it fixed itself with an update - who knows!

                             Ill keep the post updated if I notice any changes.

                              

                              

                             Jared