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.

Find returning default dialog and custom dialog

Featured Replies

This should be straight forward but it's not - to a newbie anyway.

What I'm trying to do is perform a find based on a date calculation of a membership database. If the find doesn't locate any records, it should show the custom dialog that says, "No membership renewals due in 7 days." When you hit 'OK' it will go back to  a layout called "Member Detail" and sort all the records in the database.

If it finds any records it will go to a new card window, sort them and display the records found. 

The problem is when it doesn't find any records the default Filemaker dialog pops up first saying, "No records match this find criteria." and has the usual 'Cancel', 'Continie' and 'Modify Find' buttons showing. If you hit the Continue button, then my custom dialog pops up. How do I stop the default dialog popping up and just have my custom dialog show?

The script is shown below.

Thanks,

James.

 

Enter Find Mode [ ]

Set Field [ MEMBER::Membership Date Due; Get ( CurrentDate ) + 7 & "..." & Get ( CurrentDate ) + 7 ]

Perform Find [ ]

If [ Get ( FoundCount ) = 0 ]

Show Custom Dialog [ Title: "7 Day Search Results"; Message: "No membership renewals due in 7 days."; Default Button: “OK”, Commit: “Yes” ]

Go to Layout [ “Member Detail” (MEMBER) ]

Show All Records

Sort Records [ Keep records in sorted order; Specified Sort Order: MEMBER::Name_Last; ascending ]

[ Restore; No dialog ]

Else If [ Get ( FoundCount ) > 0 ]

New Window [ Style: Card; Name: "Upcoming Membership Renewals"; Using layout: “Memberships Due In 7 Days” (MEMBER); Close: Yes; Minimize: No; Maximize: No; Resize: No;

Menu Bar: No; Dim parent window: Yes; Toolbars: No ]

Sort Records [ Keep records in sorted order; Specified Sort Order: MEMBER::Member_Name; ascending ]

[ Restore; No dialog ]

Go to Record/Request/Page

[ First ]

Else

Go to Layout [ “Dashboard” (_GLOBAL) ]

End If

  • Author

All good. After hours of trying all sorts of things, it was as simple as turning on Error Capture right at the start.

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.