Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 5906 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

In a given text field, is there a way to calculate the expression "if the field contains" (and similarly, "does not contain")?

IOW, if I had five name records:

John Smith

Mary Jones

John White

Peter Johnson

Jill Jackson

I want a calculated text field to generate a result based on whether (or not) the name record contains the word "john" (which would include John Smith, John White, and Peter Johnson).

Is there a way to do it?

Posted

The question is do you want this hard coded into your script or do you want the user to enter the data the field contains?

Hard Coded:

Enter Find Mode()

Set Field(yourfield;"John")

Perform Find()

User Enters:

create a global field g_yourfield

Show Custom Dialog(Enter data;G_yourfield[button; OK;Cancel])

If (get(LastMessageChoice)=2)

Exit Script

EndIf

Enter Find Mode()

Set Field(yourfield;g_yourfield)

Perform Find()

hth

**** My scripts almost always need some tweaking and I have not tried this in real time, but, the concept is there.

  • 1 month later...

This topic is 5906 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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