Xamarin.Forms Pages

Download Sample Download the sample

Xamarin.Forms Pages represent cross-platform mobile application screens.

All the page types that are described below derive from the Xamarin.Forms Page class. These visual elements occupy all or most of the screen. A Page object represents a ViewController in iOS and a Page in the Universal Windows Platform. On Android, each page takes up the screen like an Activity, but Xamarin.Forms pages are not Activity objects.

Pages

Xamarin.Forms supports the following page types:

ContentPage

ContentPage is the simplest and most common type of page. Set the Content property to a single View object, which is most often a Layout such as StackLayout, Grid, or ScrollView.

API Documentation
ContentPage Example
C# code for this page / XAML page

MasterDetailPage

A MasterDetailPage manages two panes of information. Set the Master property to a page generally showing a list or menu. Set the Detail property to a page showing a selected item from the master page. The IsPresented property governs whether the master or detail page is visible.

API Documentation / Guide / Sample
MasterDetailPage Example
C# code for this page / XAML page with code-behind
The NavigationPage manages navigation among other pages using a stack-based architecture. When using page navigation in your application, an instance of the home page should be passed to the constructor of a NavigationPage object.

API Documentation / Guide / Sample 1, 2, and 3
NavigationPage Example
C# code for this page / XAML Page with code=behind

TabbedPage

TabbedPage derives from the abstract MultiPage class and allows navigation among child pages using tabs. Set the Children property to a collection of pages, or set the ItemsSource property to a collection of data objects and the ItemTemplate property to a DataTemplate describing how each object is to be visually represented.

API Documentation / Guide / Sample 1 and 2
TabbedPage Example
C# code for this page / XAML page

CarouselPage

CarouselPage derives from the abstract MultiPage class and allows navigation among child pages through finger swiping. Set the Children property to a collection of ContentPage objects, or set the ItemsSource property to a collection of data objects and the ItemTemplate property to a DataTemplate describing how each object is to be visually represented.

API Documentation / Guide / Sample 1 and 2
CarouselPage Example
C# code for this page / XAML page

TemplatedPage

TemplatedPage displays full-screen content with a control template, and is the base class for ContentPage.

API Documentation / Guide
TemplatedPage Example