Sounds like your file is damaged. Use FileMaker Pro to run a recover on it to see if it can be repaired. File damage has upredictable effects damage can cause problems for one version (Such as FM PRo) and not another (Such as Go). It's also possible that the file is not damaged until it is emailed from the GO device to your Pro device. The file should be closed before it is emailed.
Things to keep in mind about Recover:
- Recover does not detect all problems
- Recover doesn't always fix all problems correctly
- Best Practice is to never put a recovered copy back into regular use or development. Instead, replace the damaged file with an undamaged back up copy if this is at all possible. You may have to save a clone of the back up copy and import all data from your recovered copy to get a working copy with the most up to date information possible.
Thanks for the reply PhilModJunk,
What are the main causes of a damaged file?
The most likely, given your scenario, is that Go is emailing an attached FileMaker file that was not first closed. Making a copy of an open Filemaker file is very likely to damage it. If you have set up Your file to email a copy of itself, then you are doing this every time you run this email a copy script. A script in an external file should instead close the file to be emailed, attach it and email it.
Users that attempt to access a file directly in a shared directory instead of using Open | Remote is another likely cause.
There are many other possibilities and you may never know which one caused the damage:
A network glitch while committing design changes back to a hosted file.
Issues with the hard drive where the file is stored
Back up software backing up an open file
A bug in the FileMaker app (dont' know of any specific bugs, but you never know...)
are all possible causes...
Thanks for your suggestions,
Could you elaborate on "A script in an external file should instead close the file to be emailed, attach it and email "?
I need to make my solution as undamageable as possible.
Create a second file with a script matching the following outline:
Close File [//specify the original file here]
Send Maile[specify your email options here]
If you want, you can then add an Open File step here to re-open the closed file and can then use another Close File step to close this send email file.
In your original file, you have a script or button that uses the Perform Script step to perform the script in this second file.
Please note that there may be issues specific to how GO operates on an iOS device that you'll need to research as I am not a GO user. You might want to post such questions in the FM GO forum (See tab at top of page.)
I don't think this would work as the file name of the original file will be different every time.
I'm guessing a variable or global variable couldn't be carried to a different file?
Why would the file name be different every time?
You can pass the current file name to the secondary file in a script parameter.
Use Get (Filename) in the optional script parameter box.
I have added the Get(Filename) script parameter to my original file. How do I use this within the second file's script? When selecting the close file script step, it won't allow me to use the Get(ScriptParameter) function
Darn, forgot that detail.
You may have to close the file manually and manually email the closed file--not what you wanted, but what is possible. Or you can keep the file name unchanged.
I seem to remember a thread in the FM GO forum that discusses emailing a Filemaker File as an attachment. You might be able to search the forums and pull up that thread...
Ah thought you were on to something there. Seems a bit strange that you can send a variable through to another file on the device but not use that variable to close the file/variable.
Is there no way to use that variable to close the file?
Not from a FileMaker Script. The step uses a direct reference to the external data source reference that identifies the file. Unlike some other steps like save as PDF or Import Records, there's no provision for a dynamic reference using a variable so it's a no go for this script step.
You never answered this question: Why does the filename change?
What problem does constantly changing the file name solve for you?
I'll describe the current method used for our solution. I know we already use Filemaker in an unorthodox way so perhaps the way our solution is used needs to be revised completely.
As mentioned before, the solution is used to carry out property inventories ans is. When developing the solution, we decided the easiest way to manage all inventories etc would be to have a separate fp7 for every property. The user starts with a 1 fp7. Enters in the property address and then a copy of the original fp7 is saved on the iPad named with the new property address. When the new copy is opened, a script runs that deletes most of the records from the original file. This way we can manage the file sizes as once an inventory has been completed, it is emailed over to us from the iPad.
Let me know if you'd like any more info.
I'd use the save a copy as with the clone option to generate an empty inventory file for download to the iPad. that way, you should be able to use an unchanging file name. After the data is sent back to your host, use import records to pull all inventory records for all properties into a single file, using a fields and tables to identify each record in the inventory by a Property ID so that you can still pull up the inventory data for a specific property.