Dr. Evil Posted January 15, 2010 Posted January 15, 2010 Hello! What is the error capture number for "Can NOT save file/find path to save file"? I have my solution running off a server, users connect to it remotely. I have a invoicing script that creates a record, in my script I have it save a PDF. of the invoice onto the hosting server. This works GREAT! But you have to be connected to the server or the file will not be able to save. So the problem is, users connect remotely to the solution, but that does not mean they are connected to the server. So when user runs script invoice, the save feature will fail unless they are properly connected. How can I prevent this problem? I'm thinking I have a few routes to solve this: a) Include in invoice script to connect to server. Have script check to see if user is connected and if not, cancel. And I do not know how to do either a or b options. Maybe there is a even a better way to solve this? Any help out there on this? THANK YOU FOR YOUR TIME!
bcooney Posted January 15, 2010 Posted January 15, 2010 Randy, it is NOT recommended that the FMS is also a shared volume. That's what your setup sounds like. True? And why save the Invoice as a PDF? I can see the need to send an invoice as a pdf attachment in an email, but not the need to permanently save the record as a PDF. Please fill me in.
Dr. Evil Posted January 15, 2010 Author Posted January 15, 2010 I wish only to save invoice as a PDF as a fail safe. For example if the FMP file got damaged, or user deleted vital data, etc... We have a server with FMP installed, it stores the solution file and is open. We (5 people) also have FMP installed on our machines. We launch FMP on our pc (mac osx) and then connect remotely. lol, did I answer your questions? Thank you!!!
bcooney Posted January 15, 2010 Posted January 15, 2010 You are launching FM Pro (not FM Server) on a file server and having it act as a host? You connect remotely using Open Remote? This really isn't the proper setup. Anyway, you can use Export Records (one record) and if that fails, the volume isn't mounted.
Dr. Evil Posted January 15, 2010 Author Posted January 15, 2010 Correct, we are not currently using FMServer. Was not in the budget... Can you tell me what the proper set up would be? So I can plan on purposing it and trying to get it approved. Yes, if not connected to the server, then saving file fails. Do you know how I could solve this problem with current situation? Thank you for your time!
bcooney Posted January 16, 2010 Posted January 16, 2010 Your setup is ok. Just be sure to use Open Remote and not all doubleclick on the file icon from the shared volume. Also, remember to close the file before you attempt to backup. As I said above, you could use Export to "ping" the shared volume, and trap for an error. You could put this in your startup script, so that anyone who doesn't have the shared volume mounted receives a warning error.
Dr. Evil Posted January 18, 2010 Author Posted January 18, 2010 yes, that is what I planned to do. I need to know the "error number" that when the export fails FMP issues. So i can set up script for Export If error ; then halt script else run script. Can this be done?
bcooney Posted January 18, 2010 Posted January 18, 2010 Yes, it can be done (and I've done it). Just test for Get (LastError) <> 0.
Recommended Posts
This topic is 5424 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 accountSign in
Already have an account? Sign in here.
Sign In Now