• 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: Error from opening a read only applet in SD
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error from opening a read only applet in SD


  • Subject: Re: Error from opening a read only applet in SD
  • From: John Stewart <email@hidden>
  • Date: Thu, 28 Aug 2003 12:06:03 -0400

On 8/28/03 at 8:30, the entity ehsan saffari spoke thusly

>global myerr
>set myerr to ""
>try
> set k to "Disk:Folder:applet"
> tell application "Finder"
> set y to k as alias
> open y using application file id "asDB"
> end tell
>on error errMsg number errNum
> if errNum = -1756 then
> -- do your stuff here
> set myerr to errNum
> else
> display dialog errMsg
> end if
>end try
>
>myerr remains as ""

It works just fine when you consider that it returns error number -43 which isn't what's being tested
for. Ergo the code to set "myerr" never gets executed, try it this way ->


global myerr
set myerr to ""
try
set k to "Disk:Folder:applet"
tell application "Finder"
set y to k as alias
open y using application file id "asDB"
end tell
on error errMsg number errNum
if errNum = -1756 then
-- do your stuff here
set myerr to errNum
else
display dialog (errNum as string) & ": " & errMsg
set myerr to errNum
end if
end try

return errNum


John
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Error from opening a read only applet in SD (From: ehsan saffari <email@hidden>)

  • Prev by Date: Works in Debugger mode... not anywhere else. Weird.
  • Next by Date: Re: as is what?
  • Previous by thread: Re: Error from opening a read only applet in SD
  • Next by thread: Re: Error from opening a read only applet in SD
  • Index(es):
    • Date
    • Thread