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.

Create new record if find is not met

Featured Replies

Hi All,

I want to perform a find in a table on a key field and if no records are found then create a new record but I can't find an error code to capture for "No records match this find criteria", can anyone tell me what it is please.

I can't find an error code to capture for "No records match this find criteria", can anyone tell me what it is please.

Read up on the Set Error Capture script step.

Hi All,

I want to perform a find in a table on a key field and if no records are found then create a new record but I can't find an error code to capture for "No records match this find criteria", can anyone tell me what it is please.

Pseudo Script

Perform Find

If Get(FoundCount)<1

show all records

New RecordRequest

End If

If you are trying to create a new record with a specific key field, store it prior to the find and then set field after creating a new record.

HTH

Dave

  • Author

Read up on the Set Error Capture script step.

Hi Vaughan,

Yes, I realised that I had to capture the error but in the Filemaker error codes I could not find the code for this specific error the nearest one I could see was code 8, Empty result.

Hint:

Set Error Capture [On]

Enter Find Mode []

Set Field [Table::Field; "non existing value"]

Perform Find []

Show Custom Dialog [Get (LastError)]

  • Author

Hint:

Set Error Capture [On]

Enter Find Mode []

Set Field [Table::Field; "non existing value"]

Perform Find []

Show Custom Dialog [Get (LastError)]

Sorry, I couldn't see for looking, I had looked at the list 5 times, 401 it is. Thank you

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.