Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: More FMP8 Questions



set my_list to cell "InvoiceID" of (every record of table "Invoices" whose cell "Status" is equal to "Open") fails if there is one found record (displaying the characters of the found cell as a list {"1","0","0"}) thing

Returning a list for the contents of one field would be normal if InvoiceID is a repeating field (with 3 repetitions) but otherwise, I'm not sure why you're getting that.



Can you think of any way to figure out the number of records in a found set in a different fashion? If I can find out the number of found records without dealing with the list command we were discussing, I can probably work around this, but I don't know of any other way.


To work with the found set you use the "document" object. So you can say, for instance:

show (every record of table "Invoices" whose cell "Status" is equal to "Open")
set num_found to count of records of document 1


or if it's just the number of records you want:

set num_found to count of records of (every record of table "Invoices" whose cell "Status" is equal to "Open")

PS. If you need to, use document "windowname" instead of document 1 (which will address the found set of the frontmost window).

--
Tim Mansour <email@hidden>

_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden
Archives: http://lists.apple.com/mailman//archives/applescript-users

This email sent to email@hidden
References: 
 >More FMP8 Questions (From: Chris Prew <email@hidden>)
 >Re: More FMP8 Questions (From: Tim Mansour <email@hidden>)
 >Re: More FMP8 Questions (From: Chris Prew <email@hidden>)
 >Re: More FMP8 Questions (From: Tim Mansour <email@hidden>)
 >Re: More FMP8 Questions (From: Chris Prew <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.