• 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
Re: Strange Error
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Strange Error


  • Subject: Re: Strange Error
  • From: Luther Fuller <email@hidden>
  • Date: Thu, 20 Jan 2011 12:19:28 -0600

Here's a complete script you can run to see the problem.

property applsAlias : (path to applications folder)
on run
tell application "Finder"
set itemList to (items of applsAlias) as alias list
end tell
repeat with i from 1 to (count items of itemList)
POSIX path of (item i of itemList)
set item i of itemList to the result
end repeat
-- itemList is now a list of posix paths
repeat with i from 1 to (count items of itemList)
set applPosixPath to (item i of itemList)
try
set itemAlias to (file applPosixPath) as alias
on error
display dialog "error"
end try
end repeat
beep
delay 1
end run --------------------------------------------

When run from a script editor, it does not error.
If saved as an application, it errors every time.

 _______________________________________________
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

  • Follow-Ups:
    • Re: Strange Error
      • From: Luther Fuller <email@hidden>
References: 
 >Strange Error (From: Luther Fuller <email@hidden>)

  • Prev by Date: Strange Error
  • Next by Date: Re: Strange Error
  • Previous by thread: Strange Error
  • Next by thread: Re: Strange Error
  • Index(es):
    • Date
    • Thread