I have made a small application in Xcode that is more or less useless. I want to make MY OWN app quit using applescript. I have opened interface builder and, in the inspector, I found the "On will close theObject" command to add to my script. I checked it, and added "beep" between the "On will close" commands. then I closed the window, and it beeped, so I know it worked. But I want something like this:
so it will do the same thing as a connection to a button under "Application". I can't stress this enough, but "TELL APPLICATION "MYAPP" TO QUIT" DOES NOT WORK!!! Please help!
Code:
On will close theObject
terminate
end will close