By Alvin Alexander. Last updated: January 25, 2018
AppleScript list FAQ: How do I get the AppleScript list size, i.e., the size of an AppleScript list (or number of items in a list)?
To get the count of the number of items in an AppleScript list, use this syntax:
set myList to {"Problem", "There was a problem", "Bummer"} set listSize to count of myList
The variable listSize
will now contain the AppleScript list size (the number of items in the AppleScript list named myList
).
(For more information on AppleScript lists, see my AppleScript list examples.)