What version of Filemaker are you using? I'm assuming from your questions that your using a fairly recent version of FMP.
The script example you've found appears to be drawn from an older version. With more recent versions of Filemaker, references to fields in scripts have changed from "Fieldname" to "TableName::Fieldname". Since your script example uses just "Fieldname", it won't perfectly match what you see in your version of filemaker pro.
My comments are in italics.
Show All Records
This works, but you can use Perform Find and specify the ! operater in the ID field to limit your found set to just those records that have a duplicate ID value if you want.
Sort Records [Restore, No Dialog] sort by ID in ascending order
Go to Record /Request/Page [First]
Replace field contents [No Dialog, 'Mark', ''''] - This is where it begins to lose me, how do I add the '''' and what does it mean?
'Mark' is the name of a field, in today's filemaker, you should see tablename::mark, where tablename is the name of the table where you'll find the definition for the field Mark.
"" is exactly what you see, two quote marks with nothing in between. To add this click the lower specify button, then choose Replace with calculated result and type in the two quote marks.
Set Field ['global', 'ID'] - how do I add the 'ID' part?
ID is the name of your ID field. Click the lower specify button. You'll see the same specify calculation dialog box you saw when you clicked the "..calculated result" option earlier. With a recent version of filemaker you want TableName::ID. Select the table which contains the ID field from the upper drop down menu. ID should now appear in the list of fields directly below this menu. Double Click ID to make it appear in the large field at the bottom of the dialog. Click OK.
Go to Record/Request/Page [ Next, Exit after last]
If ['Global = ID'] - ???
Follow the steps from the previous Set Field. WHen done, you should see [tablename::Global = Tablename::ID]. Global and ID do not have to be part of the same table.
Set Field ['Mark', '''X'''] - How do I add the '''X'''?
Click the lower specify button, type in a capital X and include one set of quotes.
Set Field ['Global', 'ID'] -????
Same as above.
Perform Find [Restore] Find records when Mark = X
Hope that Helps.
Thank you so much! I have been trying to do this for hours!
(I think you are right, that was from an older version and I'm using 9)
Thank you for saving the day! :smileyhappy: