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.

How to disable New Record command and......

Featured Replies

When I add new record, middle of data and I change my mind and cancel/delete the new record. After that new record start from new number and skip the cancel record number. Please review attached three pages. Every page is one proble alltogether three diffrent problems and problem I'm talking about is second page. If you can help me with all the problems I really appreciate. Need some desprate helppp!!

needhelp.pdf

Hi COOLROGER,

When the user cancels, you need to set the your next serial number value via the Set Next Serial Number script step. In other words, you need to create a script that deletes the record and then (re)sets the serial number for your record ID.

The field to be acted upon for this script step should be your record ID.

The calculation for the script step should be:

Max(YourRecordIDField) + 1

Replace "YourRecordIDField" with the actual name of your record ID field.

For the question about field formatting (phone numbers and social security numbers), search the forum for "field masking" or "field formatting". There are a number of posts that will show you how do accomplish this.

Hope this helps!

Cobra

but i'd hesitate to do this in a multi-user setting as you might get duplicate numbers. better to just have the gaps.

FMP 7 has the ability to only increment the serial number when the records is committed.

Alternatively, let the user enter the new data in global fields and only create the new record when they decide to "save" the new record.

  • Author

Thanks for your help guys I'm half ways with your help.

This is good

Max(YourRecordIDField) + 1

but I need a script that create a script that deletes the record and then (re)sets the serial number for your record ID.

Thanks again

This kind of re-setting serial numbers thing can barf itself in a multi-user environment. Imagine if two or more users are doing this simultaneously... Safest bet is entry into global fields, then enter them into a new record only when they decide to save the data.

Let FMP manage the unique ID numbers itself. The consequences of having duplicate IDs far outweighs having a few numbers missing.

Hi All,

COOLROGER , I think everyone else is right.

It is best to leave gaps in your serial numbers. The culprit in my solution is Max(YourRecordID). While FileMaker is calculating Max(YourRecordID), other users may be creating new records, which would not be taken into account.

Also, if someone deletes a record after another user has created a new record, Max(YourRecordID) will never be able to account for the gaps in serial numbers.

As Vaughan said, just let FMP manage the Unique serial number values itself.

Sorry about the misleading post.

Cobra

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.