Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

I have a text field called “Events”. Some of its values are as follows:

573495226_ScreenShot2021-10-09at1_44_46PM.png.38b782dd972d35f288bba33b2c529862.png

I’d like to write a script that will find all the records for which any of the values Alice_Austen_House_20?? appear and then do the following: 

1) Insert the text “Alice_Austen_House” into the Events field

2) Delete all the text Alice_Austen_House_20?? from the Events field

Here is the start of my script, intended to find the relevant records and then insert “Alice_Austen_House” into the Events field:

1355615699_ScreenShot2021-10-09at1_13_53PM.png.18adc86e554b5d2d166c9aac99c33f67.png

Here are the details of the first step of the script:

1579976270_ScreenShot2021-10-09at12_59_11PM.png.41f2d115b4c3a2c2fa256a4e8c1056b1.png

The first step correctly finds the relevant records, but then I see this error message:907062363_ScreenShot2021-10-09at1_17_31PM.png.e16331163cd4a2538b9edc83da8fe223.png

I’m puzzled by the error message because, as you can see below, I have included “Alice_Austen_House” in the value list for Events.

1024671296_ScreenShot2021-10-09at1_04_11PM.png.d70bc4e41fd9bdab832a0a939740ad62.png

What am I doing wrong? What do I need to do to get this to work?

I'm using FileMaker Pro 17 Advanced.

Posted (edited)
54 minutes ago, John Link said:

I’m puzzled by the error message because, as you can see below, I have included “Alice_Austen_House” in the value list for Events.

I believe you are experiencing the same problem as the one you did here:
https://fmforums.com/topic/106996-problem-with-script-inserting-text-into-field/?do=findComment&comment=483157&_rid=72594

Either use Set Field or at least enable the 'Select entire contents' option*.

--
(*) This is assuming Events contains a single value. If it's a checkbox or similar, then you will need to deploy a significantly different strategy.

 

 

Edited by comment

This topic is 1152 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.