MACSCRPT Archives

August 2006

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Bill Steele <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Tue, 22 Aug 2006 09:38:23 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (29 lines)
I have several scripts that search a Filemaker 8 database for 
someone's e-mail address.  Syntax:

(some stuff that gets the address to search for)
  tell application "FileMaker Pro"
	activate
	open file "Bill'sHD:subscribers.fp7"
	tell database "subscribers"
		show (every record whose cell "email" contains eAddress)
	end tell
end tell

What's fun is that it works in some scripts and not in others. It 
turns out that "@" is a wildcard character in Filemaker searches, so 
in some scripts I split the address and just look for the first part. 
If I don't, the script gives me "event not handled."  But another 
script searches for the entire address, @ and all, and it finds the 
record anyway.

In another script, by experiment I found that  "john.smith" gives an 
error "Object not found," but "smith" finds the record (and a bunch 
of others!" ).

Suggestions?
-- 

Bill Steele
[log in to unmask]

ATOM RSS1 RSS2