List count?

set this_list to {}

repeat with i from 1 to 32
set end this_list to i
end repeat

//if i dont know that it is 1 to 32, how do i find out how many places this_list has stored?

thanks

I usually use something like this, unless I need the count of the items in the list for something else.

set this_list to {Monday, Tuesday}

repeat with this_item in this_list
	display dialog this_item as text
end repeat

number of items in this_list will give you the number of items in the list. if you know they’re sequential, last item of this_list will tell you the last value in the list.

k thanks camelot