Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

UI script errors when run from project



I'm trying to incorporate a UI script into my project. The code works fine in Script Editor, but errors when run from my project:

on activateGrapher(graphType)
tell application "Grapher"
activate
end tell
log graphType
tell application "System Events" <--error here
log 1
tell process "Grapher"
log 2

The error dialog is:

System Events got an error: NSReceiverEvaluationScriptError: 4 (1)

The reference guide tells me 'the object or objects specified by the direct parameter to a command could not be found'. But I don't understand what can be wrong.

MarkB
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-studio mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-studio/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.