Re: AppleScript-Users Digest, Vol 4, Issue 504
Re: AppleScript-Users Digest, Vol 4, Issue 504
- Subject: Re: AppleScript-Users Digest, Vol 4, Issue 504
- From: "Mr. George" <email@hidden>
- Date: Wed, 17 Oct 2007 11:52:07 -0700 (PDT)
Hi Nick,
You can try this code. It requests the users to select the album from a list of
albums, eliminating the possibility of having two selections causing an error,
or false result. This scrip could be made to handle multiple selections if
needed.
tell application "iPhoto"
--get name of all albums
set all_albums to name of every album
--user picks which album to choose
choose from list all_albums --with multiple selections allowed
set choice_album to result
set choice_album to item 1 of choice_album
set num_of_photos to count photos in choice_album
end tell
George
>
> Thanks for that.
>
> current album works for me too - I hadn't thought of that.
>
> It does break though if someone has 2 albums selected in the iPhoto
> window, so it would be great if there was a way to work with the
> values returned by get selection (if 2 albums are selected that
> returns the id of each of them and I could work through them both).
>
> Cheers
>
> Nick
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden