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

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

Recommended Posts

  • Newbies
Posted

HI... newbie here

A client has requested that I modify their existing Filemaker project in such a way that their users can click a button in order to duplicate all entries in a given record (i.e. client wants to duplicate record 250 of 500 and then just modify certain parameters).

The problem is this: the Filemaker project consists of a layout that uses repeating fields from 2 separate tables: Sitems and Selection Form.

The duplicate record function does create a new record, however the data that was in the original record is not carried forward to the newly created record.

Can anyone provide some advice?

Posted

This is not so simple as it seem on first look. FileMaker does not care what is happening to related records.

You have to script duplicating your record and related records ( on each related duplicate record you have to set RecordID to new original duplicated recordID )

Original recordID is 1, you duplicate it so it get recordID 2. Then you have insert 2 in each duplicated related record.

HTH

  • Newbies
Posted

Thanks for the advice...

I found a roundabout, though admittedly not the best, way of accomplishing what I wanted. It is not elegant, but at least it works.

I performed a Find on the record that was to be duplicated (i.e. 250 of 500) and then created an elaborate script that simply went back and forth between a new record and the current find, field repetition by field repetition, copying and pasting the data back and forth.

The strobe-like effect of transitioning between records leaves me somewhat dizzy - harkening back to the drug ingesting 70s - but the client could not care less...it works, and that is all they wanted.

Thanks

Posted

Hi Rick,

The flashing can be elimiated by placing a

Freeze Window

script step before the back&forth process and a

Refresh window

script step after the process is done.

HTH

Tim

  • 3 weeks later...
  • Newbies
Posted

You could always - before duplicating - set a number of local script variables to the fields you wish to copy through, then do your duplication, go to the duplicate, and set the desired fields to the relevant local variable. That way if you set 20 fields, rather than going back & forth 20 times you can do it in 1. That'll fix the freeze issue to a significant degree, but I also agree with the previous poster that its best to leave freeze/refresh in there as well.

This topic is 6550 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.