I’m new to Filemaker Pro and I don’t know much about AppleScript either. I would like to replace every occurrence of a particular character (ch1) in the text field Notes with another character (ch2). My Filemaker database contains more than 5000 records, so I need a script to perform this task. Filemaker Pro is supposed to be scriptable. Can anyone provide a solution using AppleScript? Can this problem be solved within the framework of FileMaker Pro, without AppleScript?
I’ve never worked with version 4.3 but I have worked with versions 6 and 7 a bit. I would guess you could write a script within FMP that would find and replace the characters in a specific field.
An AppleScript would be something like this
tell application “Filemaker Pro”
–i’m assuming you’ll only have this db open so no validating the db and getting to the correct one
tell front document
set recordCount to count of every record
repeat with i from 1 to recordCount
set notes to cell “Notes” of record i
if notes = ch1 then
set cell “Notes” of record i to ch2
on error errMsg
display dialog "There was an error in Filemaker Pro converting record " & i & return & return & errMsg