Timothy Moser Posted August 13, 2009 Posted August 13, 2009 Is there a difference, any difference in the world, between editing a record by clicking on modifiable fields and editing a record by running a script that uses nothing more than the "Open Record/Request" command? I have a problem with FileMaker crashing when I commit records in some of my layouts. It freezes, and if I force quit it and restore the file, I find that it has added thousands of empty records to the tables. But the thing is that this only happens if the way I first got into the record is when I have used the script. I reduced the script to one line, "Open Record/Request", and still the problem happens. It does not happen when I simply click in a modifiable field and then commit the record. I am getting pretty tired of restoring files and mass-deleting empty records.
IdealData Posted August 13, 2009 Posted August 13, 2009 Is there a script trigger at work here? The empty records suggest there is a script trigger defined to create a new record and is acting recursively.
Timothy Moser Posted August 13, 2009 Author Posted August 13, 2009 (edited) Selecting the script from the menu does the same thing. Incidentally, there is a global field in the table that displays on the layout, and whenever I commit the record after having used the script to open it, it looks like the global field is selected while the program sits there frozen. Could that have anything to do with it? It still does not explain why the single-line script is different from simply modifying the record. Edit: No, deleting the global field from both the layout and the database did not help. Edited August 13, 2009 by Guest
Timothy Moser Posted August 13, 2009 Author Posted August 13, 2009 Hold on; you were right. There actually is a script trigger that activates when a record is committed in this layout, and turning it off fixes the problem. I just have to figure out why the problem only happens when the record is opened a certain way.
Timothy Moser Posted August 13, 2009 Author Posted August 13, 2009 Fixing some problems in the script seem to have solved the problem. Thanks for your help. Still, I do not understand why opening the record one way is different from opening it another way.
IdealData Posted August 13, 2009 Posted August 13, 2009 Script Triggers only happen under certain situations - please check out the help system.
Vaughan Posted August 13, 2009 Posted August 13, 2009 ... if I force quit it and restore the file, I find that it has added thousands of empty records to the tables It sound as though the interaction with the script trigger was causing the creation of new records... it appeared frozen because it was in an infinite loop. Ummmm, you know that putting restored files into production is not good practice...
Timothy Moser Posted August 13, 2009 Author Posted August 13, 2009 Is there something wrong with restored files? I have been testing mine and they do not seem to have many problems, although sometimes things will be missing and I have to add them from previous versions of my database.
IdealData Posted August 16, 2009 Posted August 16, 2009 Take heed Timothy. If you have things missing from a recovered file then it is almost certainly damaged - do not proceed with even a suspect file. Make a copy of your file(s) before testing unknown areas, and revert to the backup if your tests fail.
Timothy Moser Posted August 17, 2009 Author Posted August 17, 2009 I am doing more backups now so that I do not have to use recovered file. The file I am currently using is based on a file that was once recovered, but it seems to be fine. Thanks for the advice.
Recommended Posts
This topic is 5578 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