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

  • Newbies

Hello All,

This may have been addressed before and I am very new to scripting in filemaker.  Basically what I am trying to create is a script where I can find records from a carriage return separated list.  I have created a field and a button to execute the script.

For Example: If I have 50 records for every US State, in the field I could put:

California

Nevada

Oregon

Thus populating just the 3 records.  

 

Any help would be greatly appreciated.

 

Assuming you have entered the three states to find into a global field named gStates, you could have your script do:

Enter Find Mode []
Loop
  Set Field [ YourTable::State; GetValue ( AnyTable::gStates ; Get ( RecordNumber ) ) ]
  Exit Loop If [ Get ( RequestCount ) ≥ ValueCount ( AnyTable::gStates ) ]
  New Record/Request
End Loop
Perform Find []

 

  • Author
  • Newbies

Thank  you for your quick response.

I get an error that an operator is expected in the following portion:

Set Field [ YourTable::State; GetValue ( AnyTable::gStates ; Get ( RecordNumber ) ) ]

Thanks

  • Author
  • Newbies

I'd like to add it wouldn't be searching a global field, but all existing records.  If that helps?

It's getting its list from the global field, to then search all records...

  • Author
  • Newbies

Ok looks like it searches successfully if I just have 1 "State" in my find field.  If I add any more it just errors out and finds zero.

I am probably using the Set Field portion incorrectly.

Thanks for the help

20 minutes ago, surfninja13 said:

 If I add any more it just errors out and finds zero.

Does this work for you?

MultiFind.fp7

  • Author
  • Newbies

YES!  Thank you very much, I also figured out how to format the Set Field step correctly.

 

Best,

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.