I am new to programming for the iPhone, and this will be my first question. I have experience working with different languages such as php / java / C ++.
My question is about ViewControllers and views in iOS.
I started a project that will contain several different things, such as the login screen, the main screen, and several other screens. The goal of this project is to learn how to create everything programmatically, and not use the interface designer to get used to the system. I am using the book: “Advanced iOS 4 Programming” to help me.
I managed to create all the screens (and things like logging-in work), but I'm not sure if I did it right.
All my code for creating text fields / labels / buttons is now in the ViewController, while the main view, where everyone is wearing, is almost empty and nothing is done in it. Should the code for creating text fields and other components be in the view itself or is this the right approach?
I looked at several different examples, but most use an interface constructor. The book itself is also not very clear on this issue.
Thanks in advance.
Regards, Jasper
source share