Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

I want to be able to duplicate a number of found records in one of my databases. I am having trouble setting it up so that after the first record it finds the next record to duplicate.

Right now it find the first record, clears the seleted info, and stops because it puts the duplicated record at the end.

Anyone with any help?

Thanks

I did this once using a looped script. I always needed to duplicate a set of records created about a month ago, so I used the created date field as a marker.

I would send it back to the first record and omit it at the end of each loop, then check if the current record was created on todays date. If so, it would exit the script. It served my purposes.

It looked a little like this:

Go to Record/Request/Page [First]

Loop

If [Date_Created = Get(CurrentDate)]

Exit Script

Else

Duplicate Record/Request

Go to Record/Request/Page [First]

Omit Record

End If

End Loop

It's been a while since I used this, though, so I don't remember if I got the order quite right.

How it behaves, will depend on whether the database is sorted or not. You should add an Unsort step at the beginning of the script. Then, you are guaranteed that new records will be placed at the very end of the file.

Sort( on Any field better unique)

Loop

Duplcate record/Request

Go to Record [Next] exit after last

Endloop

Another option that works well is to start from the end and work backwards. Sort order is irrelevant and Omit is quite fast. It also allows one to work on the newly duplicated record, setting any additional fields before moving on; as well as 'returning' to the original record to capture anything from the newly created one, such as the new record's unique ID (for cross-reference) or the new Auto-Enter (which may end up different from the original record).

I use this for creating new Activity records and the new assigned person may be different from the original - but the newly assigned person is inserted back into the original as "Work turned over to bla bla, Activity ID bla bla" If using Insert From Last Visited, the fields must be on the layout.

It allows everything to be completed in one pass and provides great flexibility. The theory of this method is also easy to remember and work with. It would look like this (once you have your found set) ...

Go To Record/Request/Page [ Last ]

Loop

Duplicate Record/Request/Page

... do whatever you wish to the new record ...

Omit Record

... do anything you wish to the original record (plus insert stuff from the new) ...

Omit Record

Exit Loop If [ not Get(FoundCount) ]

End Loop

Show All Records

Admitted, you will lose your original found set. But I've found that with this method, I can do everything needed to the set of records as I progress so there is no need to retain the found set.

On a Mac: perform applescript: duplicate every record

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.