Table of Contents
Method 1 of 1:
Snow Leopard and Later
-
Images 1 of How to Make a Simple Program With Xcode Beginning with Snow Leopard, Apple has deprecated the use of Applescript Studio, but fear not, in spite of a bit of extra typing, things are actually better without it. Go ahead and grab Xcode 3.2.5 or later. You can get 4.0 in the Mac App Store for free. -
Images 2 of How to Make a Simple Program With Xcode File>New Project -
Images 3 of How to Make a Simple Program With Xcode Click Applescript Application -
Images 4 of How to Make a Simple Program With Xcode Name your project, this example is named "Talking Example" -
Images 5 of How to Make a Simple Program With Xcode Your project should appear -
Images 6 of How to Make a Simple Program With Xcode Double click "Talking_ExampleAppDelegate.applescript" -
Images 7 of How to Make a Simple Program With Xcode There are already some items filled in for you. After the property declaration, insert a new handler:- on clickedme_(sender)
- say "hello"
- end clickedme_
-
Images 8 of How to Make a Simple Program With Xcode Type Cmd+B to build -
Images 9 of How to Make a Simple Program With Xcode Now double-click MainMenu.xib -
Images 10 of How to Make a Simple Program With Xcode Interface builder should open. Close any xib windows it brings up from previous projects you may have worked on. -
Images 11 of How to Make a Simple Program With Xcode A blank window should appear and you can drag a button onto it from the Library. -
Images 12 of How to Make a Simple Program With Xcode Double click the button and make it "Hello" -
Images 13 of How to Make a Simple Program With Xcode CTRL-drag from the Hello button to the blue cube called "Talking Example AppDelegate" and let go. You can now pick the clicked-me event handler to link to the "Hello" button you just made. -
Images 14 of How to Make a Simple Program With Xcode Now click file > save. You many now quit interface builder. -
Images 15 of How to Make a Simple Program With Xcode In Xcode, press build and go at the top. Your application should run smoothly.
4 ★ | 2 Vote