February 19, 200421 yr Hello I have an event each week that constitutes the file I am using. The file is called registration and it interacts with several other files for lookups etc. The group used to keep the whole thing in a file and it got so big that the printing was a real time thing. We want to get rid of the big file and just have a little file that we back up to the bigger file/ The little file will be empty at the beginning of the weekly event and then grow to 300 records of so. At the end of the event we want to make a script that will automate the merging of the little file into the archive. Any suggestions on doing this the best way with a script? Thanks STAN
February 19, 200421 yr Hi Stan, If your archive file matches the 'live' file in structure (same fields, same names etc), then you can simply create a script in the archive file which imports the found set from the current file using the 'matching records' option. Then you can create a script in your current file which archives the current batch of records to get ready for a new week. Something along the lines of: Show Message ["Are you *sure* you want to archive all the current records?" "Cancel", "Archive"] If ["Status(CurrentMessageChoice) = 2"] Show All Records Perform Script [sub-scripts, External: "Archive.fp5"] Delete All Records [No Dialog] End If - where the external script at step four calls the import script in the archive file. Whenever the script is run it will leave you with an empty file ready for a new batch of records, and the previous batch will be in the archive file instead (where they will appear as the found set until the file is closed).
Create an account or sign in to comment