Search code examples
c#iosipadxamarin.iosuisplitviewcontroller

Setting up Split View Controller Xamarin.iOS


Im getting really stuck on how to implement a split view controller in Xamarin ios. I have put the split view controller into the storyboard but have done no coding because I don't even know how to reference the master and detail views in the C# code. All the tutorials I have searched through are either in swift or objective-c for obvious reasons.

If I do find an xamarin tutorial then its all done through XAML which i'm not using as its not cross platform. I really need help on just getting the basics of the split view controller set up such as populating the tableview in the master view with the different pages I need.

Hopefully someone can give me a basic run through of getting the very basics set up please.

Many Thanks Jamie


Solution

  • Refer to this tutorial.

    First, add SplitViewController to storyboard, then name MasterViewController and DetailViewController as below, it will create class file automatically in your application folder, so you can write reference code in it.

    enter image description here