• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Scripting an AppleWorks database
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scripting an AppleWorks database


  • Subject: Re: Scripting an AppleWorks database
  • From: Nigel Smith <email@hidden>
  • Date: Fri, 02 May 2003 17:22:35 +0100

On 2/5/03 6:52, "Jeffrey Mattox" <email@hidden> wrote:

> I can use the "unavailable" keyword for a text field, but not for a
> number field. If any of the records has an empty value in the number
> field, I get an error.

"Whose" appears to be broken when looking for "unavailable" in number
fields.

So it is back to the slow old ways -- iterating through the records,
building a list, then hiding those records that are in the list:

tell application "AppleWorks 6"
set idList to {}
tell document 1
repeat with x from 1 to count of records
set tmp to value of field "test3" of record x
if tmp is unavailable or tmp < 3 then
set end of idList to id of record x
end if
end repeat
repeat with eachId in idList
hide record (contents of eachId)
end repeat
end tell
end tell

The above will hide all records with a value less than 3 in field "test3",
including those with no value at all.

HTH,

Nigel
_______________________________________________
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.

References: 
 >Re: Scripting an AppleWorks database (From: Jeffrey Mattox <email@hidden>)

  • Prev by Date: Re: mac to unix path names
  • Next by Date: Re: When a string is not a string for Palm Desktop
  • Previous by thread: Re: Scripting an AppleWorks database
  • Next by thread: Re: Script in Script Editor MUCH faster than compiled app -- why?
  • Index(es):
    • Date
    • Thread