John Costanzo

Basic Cocoa App

Well I started looking into Cocoa programming so I could develop some Mac applications. So here is my first tutorial on how to develop using Objective-C language.

I will post the Hello.h and the Hello.m files cause I know they are tuff to read.

//  Hello.h
//  HelloWorldApp

//  Created by John Costanzo on 7/13/09.
//  Copyright 2009 JC Web Concepts. All rights reserved.

#import
@interface Hello : NSObject
{
    IBOutlet NSTexField *textField;
}
- (IBAction)sayHello:(id)sender;
@end
//  Hello.m
//  HelloWorldApp

//  Created by John Costanzo on 7/13/09.
//  Copyright 2009 JC Web Concepts. All rights reserved.

#import "Hello.h"
@implementation Hello
- (IBAction)sayHello:(id)sender
{
  //Say Hello
  [textField setStringValue:@"Hello, World!"];
}
@end