Skip to Main Content
Xamarin.Forms Projects
book

Xamarin.Forms Projects

by Johan Karlsson, Daniel Hindrikes
December 2018
Intermediate to advanced content levelIntermediate to advanced
416 pages
10h 30m
English
Packt Publishing
Content preview from Xamarin.Forms Projects

Using RepeaterView

To add a custom control to a view, we need to import a namespace to the view. If the view is in another assembly, we also need to specify the assembly, but in this case, we have both the view and the control in the same namespace, as shown in the following code:

<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"              xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"              xmlns:controls="clr-namespace:Weather.Controls"              x:Class="Weather.Views.MainView" 

Follow the steps below to build the view:

  1. Add a Grid as the root view of the page.
  2. Add a ScrollView to Grid. We need this to be able to scroll if the content is higher than the height of the page.
  3. Add RepeaterView to ScrollView and set the direction to Column so the ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Xamarin.Forms Projects - Second Edition

Xamarin.Forms Projects - Second Edition

Daniel Hindrikes, Johan Karlsson
Xamarin Blueprints

Xamarin Blueprints

Michael Williams
Xamarin.Forms Solutions

Xamarin.Forms Solutions

Gerald Versluis, Steven Thewissen

Publisher Resources

ISBN: 9781789537505Supplemental Content