Question

I have a UI file in xcode, and I have an AppDelegate class with an awakeFromNib function. From this function, is there a way to change properties of objects which are in the UI? For example, change the string of a label, textfield and so on.

Sorry for bad english, tried to explain as well as I could.

Any help would be very appreciated!

—Albé

Was it helpful?

Solution

You should read Apple's Currency Converter tutorial if you haven't already. It will give you the basics on Cocoa.

In short, you declare IBOutlets to the objects you wish to reference, and in Interface Builder, you create the connections between those outlets and the objects. After that, you can reference the objects via the outlets, which are really just pointers.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top