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: alias list error



On 31/3/07 8:56 AM, "Jim Brandt" <email@hidden> wrote:

> Can someone explain how I can fix this statement so that it works every time.
> Right now, it works if there are two or files in the folder, but fails if only
> a
> single file exists.

try
set theList to (every item of folder hold_folder whose kind is not "folder")
as alias list
on error
set theList to (every item of folder hold_folder whose kind is not "folder")
as alias as list
end try

-- 
Shane Stanley <email@hidden>
AppleScript Pro Denver, June 2007 <http://scriptingmatters.com/aspro>


 _______________________________________________
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/archives/applescript-users

This email sent to email@hidden

References: 
 >alias list error (From: Jim Brandt <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.