• 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
launch command bug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

launch command bug


  • Subject: launch command bug
  • From: Luther Fuller <email@hidden>
  • Date: Tue, 29 Oct 2013 14:40:20 -0500

I have just gotten around to checking my launch command test scripts in Mavericks.
Recall that the launch command should NOT send the 'run' command to the launched application.
The bug in Mt. Lion and Mavericks is that it does incorrectly sends the 'run' command.

Here are my test scripts, followed by the results in Lion, Mt. Lion and Mavericks.

-- compile as an application bundle named "CallingApp.app"
on run
tell application "Finder"
(container of (path to me)) as alias
set hostAppl to (the result as text) & "main.app"
end tell


try
launch application hostAppl
tell application hostAppl
doSomethingElse() -- comment out and see what happens
end tell
on error errText number errNr
activate me
"CallingApp Error = " & errNr & return & errText
tell me to display dialog the result buttons {"OK"} default button 1
end try
end run -----------------------------

and

-- compile as an application bundle named "main.app"
on run
activate me
tell me to display dialog "Running" buttons {"OK"} default button 1
end run

on doSomethingElse()
activate me
tell me to display dialog "What do you want to do?" buttons {"OK"} default button 1
end doSomethingElse

Put both applications in the same folder. Double-click "CallingApp" to start the test.
And my results are …

Lion -----------------------------
Only the "What do you want to do?" dialog appears. This is the correct behavior.

Mt. Lion --------------------------
The "Running" dialog appears. (incorrect, 'launch' has sent the 'run' command.)
Click "OK" to get ...
the "Error -609" dialog.

Mavericks ------------------------
The "Running" dialog appears (again, 'launch' has sent the 'run' command.)
behind the "What do you want to do?" dialog.
There is no "Error -609" dialog.

The behavior of the 'launch' command has changed in Mavericks,
but the bug ('launch' sends the 'run' command) is still there.



 _______________________________________________
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

  • Prev by Date: Re: ASEditor Drag&Drop
  • Next by Date: Re: Article on missing Applescript in new iWork
  • Previous by thread: Bug Fixes: Mail Headers in Mavericks
  • Next by thread: Make Bwana work with recent Safari releases
  • Index(es):
    • Date
    • Thread