Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

baddj

macrumors 6502
Original poster
Mar 4, 2009
352
35
Hello.

I have been trying for over 3 hours trying to make a button change text in a textfield but all i get is errors a baby can code something like this in windows but not in OSX ;) so hows it done and do not say the google word coz i have done that.
 

Catfish_Man

macrumors 68030
Sep 13, 2001
2,579
2
Portland, OR
You're pretty terrible at using Google. There's dozens of step by step tutorials out there, for a variety of skill levels.

Code:
- (IBAction) doStuff:(id)sender {
    [someTextField setStringValue:@"Hooray text!"];
}

plus hooking up the button and textfield in Interface Builder.
 

baddj

macrumors 6502
Original poster
Mar 4, 2009
352
35
Sorry for my mood but i had a windows programmer trying to help me and he was getting ****** at xocde and it was passing onto me.

ill give that ago but whats the best place to get a good refrense on the valuables like setStringValue etc.
 

Guiyon

macrumors 6502a
Mar 19, 2008
771
4
Cambridge, MA
Go to the "Help" menu and select "Documentation" while within XCode. Then just type in the class you are looking for information on.
 

Sayer

macrumors 6502a
Jan 4, 2002
981
0
Austin, TX
Yeah once you get it down, making a Cocoa app is fairly easy for most things.

Just don't forget you connect the UI elements in Interface Builder. In fact a new app should start in Interface Builder, which can generate source code files that match the UI elements (naming conventions, links to classes).
 

admanimal

macrumors 68040
Apr 22, 2005
3,531
2
Why not look at one of the dozens of sample apps that are included with XCode? They cover pretty much all of the basics.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.