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

Preparing the data for visualization

Before we can visualize the data on the map, we need to prepare the data. The first thing we will do is create a new model that we can use for the prepared data. Let's set this up by going through the following steps:

  1. In the Models folder in the MeTracker project, create a new class and name it Point.
  2. Add properties for the Location, the Count, and the Heat, as shown in the following code:
namespace MeTracker.Models{     public class Point    {         public Location Location { get; set; }         public int Count { get; set; } = 1;         public Xamarin.Forms.Color Heat { get; set; }    }} 

The MainViewModel will store the locations that we will find later on. Let's add a property for storing the Points by going through the following ...

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