Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 8802 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

ok i'll get straight to the point. i'm trying to make a script that will have you enter in something for a field and it finds all the records that have that in that field and then sends them to an archive of all the records and then deletes the ones that you sent in the current file. I havent been very successful so far and any help will be appreciated.

Posted

quote:

Originally posted by RealtyIntern:

ok i'll get straight to the point. i'm trying to make a script that will have you enter in something for a field and it finds all the records that have that in that field and then sends them to an archive of all the records and then deletes the ones that you sent in the current file. I havent been very successful so far and any help will be appreciated.

You should be able to do this without much trouble. Basically, have a script enter the find mode, pause and let the user enter the search criteria, continue and you have your found set. Run a script in your archive file (if it's a FMP file) that imports the data from the file with the found set. Importing from one FMP file to another will work only with the records in the found set. Then you can delete the records in the found set.

Chuck

  • 2 weeks later...
Posted

You don't have to run the script in the archive file manually. In your main database use the perform script [sub-script, External] step. The external script is actually in the archive database, and simply consists of the Import Records script step. Your script should look something like this:

Enter Find Mode

Pause

Perform Find

Perform Script [sub-scripts, External "Archive"]

Delete All Records

Hope this helps!

  • 2 weeks later...
Posted

Just be aware that this solution only works for single-user solutions. The reason for this is that import command will stall with multi-user setups because guests cannot perform imports.

The work-around that I have come up with is to mark the records with the script but leave them there. The actual importing needs to be done from the server itself. I get this to happen by closing all the databases, back them up, then restart them. The import is done with a startup script that runs automatically on restart.

If there is a more elegant way. plesae let me know.

This topic is 8802 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.