From the course: Xamarin Essential Training: Create Your First App

Unlock the full course today

Join today to access over 23,200 courses taught by industry experts.

Define view controllers

Define view controllers

- [Instructor] Let's go ahead and set up our controllers. Now these are going to be the code that sits behind our user interface and we've been given this ViewController but I'm going to change the base class to a UITableViewController because I want to be able to display a table which is the iOS parlance, or term, for a list of those products on this main view controller. I go Add a new view controller, I do a New File, go to iOS here, you can see we've got a number of different options down at the bottom. This ViewController, I'm going to change that to ProductDetailViewController. You'll notice that one is deriving from a UIViewController, and that's okay. I am just going to have a UI view here. I'm going to put some labels for my product information and so that gives me the control that I need to display some basic information. We've got those lifecycle events so the view did load is where I can do additional setup…

Contents