OK, I have a Cocoa app that I'm working on. It's a very simple app that is only used in-house. And there's only one AppleEvent that I need to handle.
The way it works, (just for some background, not too important) when the user clicks a button in FileMaker, it launches an AppleScript. This AppleScript sends one event to my app, and my app does stuff. Very simple.
So, what I've done so far:
- in my "Info.plist" file, I've added the "NSAppleScriptEnabled" flag and set it to "YES"
- I've created an 'aete' resource with my custom event in it. This is an 'aete' resource instead of a "scriptSuite" file, because I couldn't get the "Script Editor" to recognize my app as scriptable. But when it's an 'aete' resource it does. I've seen some other apps do this, like TextWrangler, so it must be OK to do.
</x-tad-smaller>And my handler looks like this:<x-tad-smaller>
- (</x-tad-smaller><x-tad-smaller>void</x-tad-smaller><x-tad-smaller>) upgradeHandler:(NSAppleEventDescriptor*)event withReply:(NSAppleEventDescriptor*)reply;
Right now, I'm just running from script from Script Editor. And I have a breakpoint in my routine, but it never gets there, and all I get is this lousy message:
"AppX got an error: Can't continue Upgrade."
where Upgrade is the name for my custom AppleEvent.
This is driving me crazy! Is there any kind of AppleEvent debugging or something? I just wish I knew where the event is going.
Thanks for any help in this matter,
P.S. - If there's a sample project out there which implements a few (or just one) AppleEvent, and has scripting support (like this) I'd love to see the project, so I can figure out what I'm doing wrong.
Do not post admin requests to the list. They will be ignored.
Applescript-implementors mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden