• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Please explain this!?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Please explain this!?


  • Subject: Please explain this!?
  • From: Harald E Brandt <email@hidden>
  • Date: Fri, 23 Nov 2001 12:26:02 +0100

tell application "Finder" to (folders in extensions folder whose name starts with "a")
-- {folder "ActiveX Controls" of folder "Extensions" of folder "System Folder" of startup disk of application "Finder"} --Fine, that's expected. Now, pick that folder:

tell application "Finder" to item 1 of (folders in extensions folder whose name starts with "a")
-- {file "AdobePS" of folder "Extensions" of folder "System Folder" of startup disk of application "Finder"}

--What??? A file! That should be impossible!?
--I'm picking the first in a list of folders, and expect a folder!
--Compare with:

tell application "Finder"
set theList to (folders in extensions folder whose name starts with "a")
item 1 of theList
end tell
-- folder "ActiveX Controls" of folder "Extensions" of folder "System Folder" of startup disk of application "Finder"
--That's what I wanted (although my real scripts are not about extension folder, but the principle error is the same)


My scripts run havoc! I need to understand what the hell is going on with filtering!!

______heb________________________________________________________________
Harald E Brandt email@hidden PGP/MIME aware http://heb.bragit.com


  • Follow-Ups:
    • Re: Please explain this!?
      • From: Paul Berkowitz <email@hidden>
    • Re: Please explain this!?
      • From: Hugh Dixon <email@hidden>
  • Prev by Date: Re: how to quit a script
  • Next by Date: Re: gary Brown/Frankel is out of the office.
  • Previous by thread: Script to run at shutdown in X
  • Next by thread: Re: Please explain this!?
  • Index(es):
    • Date
    • Thread