August 20, 200718 yr Does anyone out there know if it is possible to override the auto-enter settings for a field temporarily as a script step. Specifically, if I want to import some records and modify them witha few subsequent calculations, I don't want the Date Modified field updating. I wanted to avoid having to re-import the date field again afterwards. cheers - Anatole
August 20, 200718 yr It could be possible to put in conditional aut-enter calculations, but it'd massively complicate things. (I'd hate to be the person maintaining the database.) Since the process is scripted, it's easy just to let the auto-enters happen theloop through the found set of records and use Set Field[] to over-write the auto-entered values.
May 20, 200916 yr What about if the date modified is being auto entered? you can back up the original date, then change the fields you want. the date modified will be auto entered to the current date. then in the script you set the modified date back to it's original, but by changing the field it auto enters the current date again. How can i get around this?
May 20, 200916 yr Turn off the auto-enter, do the record mods, then turn the auto-enter back on again.
May 21, 200916 yr You can turn off auto-enter during import. If there's additional processing to be done, you could import to a temp table and do it there, before importing to the "real" table.
May 21, 200916 yr How do i turn off the auto-enter? if you mean modifying the field definition manually, that's not gonna help. It has to be automated.
May 21, 200916 yr It's an option you get when you set up the import (both manually and in a script). It's turned off for the duration of import only.
May 21, 200916 yr I want it to work inside a script, without using an import. I'm not using the import script step. I want to change a field without the modified date changing. I don't think that's possible without editing the field definition.
May 21, 200916 yr I've got an idea. I'm gonna make a new table that will hold the date at the beginning of the script. then at the end of the script i will import the date (with auto-enter turned off). It's not simple but it should work. Thanks for the idea of using import with auto-enter turned off.
May 21, 200916 yr I don't think that's possible without editing the field definition. Anything (almost) is possible - the question is whether it's also desirable. For example, you could define a DateModified2 field with auto-entered calculation = Case ( gAutoEntryOff ; DateModified2 ; DateModified ) where gAutoEnterOff is a global field. Then have your script set the global to 1 before changing any values, and back to 0 or empty when done. Or you could use the script name as the condition. However, I am not at all convinced this is better than doing the processing in a table where there are no auto-enters at all.
May 21, 200916 yr Here is a sample. See if this works for you. *Edit - Ah Michael pretty much covered it. timestamp_test.zip Edited May 21, 200916 yr by Guest
June 10, 200916 yr Turn off the auto-enter, do the record mods, then turn the auto-enter back on again. It is possible to do this as a script step in Filemaker 6?
Create an account or sign in to comment