Re: Scripting an AppleWorks database
Re: Scripting an AppleWorks database
- Subject: Re: Scripting an AppleWorks database
- From: Deivy Petrescu <email@hidden>
- Date: Wed, 30 Apr 2003 17:10:02 -0400
On Wednesday, April 30, 2003, at 04:52 AM, Jeffrey Mattox wrote:
>
I am just learning how to script an AppleWorks database, and have run
>
into a problem.
>
>
tell application "AppleWorks 6"
>
every record of document 1 whose value of field "status" is
>
"ready"
>
end tell
>
>
The "status" field is a text field. If every record in the database
>
has a non-blank value for the "status" field, everything is fine and I
>
get a list of records. However, if one or more of the records has an
>
empty status field, the middle line fails with:
>
>
AppleWorks 6 got an error: A descriptor type mismatch occurred.
>
>
I cannot guarantee that every record is filled in. How do I get a
>
list of records that match a condition, and skip those where the field
>
is empty?
>
>
Jeff
>
Jeff, this works:
tell application "AppleWorks 6"
every record of document 1 whose value of field "status" is not
unavailable and value of field "status" is "ready"
end tell
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.