How can I add a list of items to a collection with AppleScript? I can
add one item at a time, but for large sets of items this is a pokey
(although watching the item count next to the collection icon climb is
kind of interesting). The scripting dictionary implies that you can
add more than one object at once, but I can't seem to figure out the
syntax.

Here's an example. An arbitrary number of new items are created and
appended to a list; then, a new collection is created and I attempt to
add the list of items to the collection. I'm warned that the bookmarks
list can't be "converted into type reference."

tell application "Yojimbo"
        
        set _bookmarks to {}
        set end of _bookmarks to make new bookmark item with properties 
{name:"Foo"}
        set end of _bookmarks to make new bookmark item with properties 
{name:"Bar"}

        set _collection to make new folder collection with properties 
{name:"Test"}
        add _bookmarks to _collection
        
end tell

Any corrections or suggestions?

Jim

--
------------------------------------------------------------------
This message is sent to you because you are subscribed to
 the mailing list <yojimbo-talk@barebones.com>.
To unsubscribe, send mail to: <[EMAIL PROTECTED]>
List archives:  <http://www.listsearch.com/yojimbotalk.lasso>
Have a feature request, or not sure if the software's working correctly? Please send mail to: <[EMAIL PROTECTED]>

Reply via email to