This is weird. Don’t know what is happening. When I run this:
repeat 5 times
set the_app to choose application
tell the_app to activate
end repeat
The chosen apps’ windows become frontmost. Even the iTunes window! On the other hand, When I activate the apps with tell app “SomeAppName” to activate its window is not frontmost.
Model: MBP
AppleScript: 2.2.4
Browser: Safari 536.26.17
Operating System: Mac OS X (10.8)
Update, I have to do this to activate an application:
tell application "iTunes"
activate
activate
end tell
I noticed this about three months ago, but couldn’t find anything on this since then. This happens even when run from a script app. ‘activate’ doesn’t work anymore.
tell application id "com.apple.systemEvents"
if visible of application process "iTunes" then
set visible of application process "iTunes" to true
end if
if not frontmost of application process "iTunes" then
set frontmost of application process "iTunes" to true
end if
end tell
You are not the only one I have heard about with pram/efi ram problems, I think you, and everybody else, should password protect it.