Getting started

For OS X

1. Open Xamarin Studio

3306

Launch Xamarin Studio on the Mac.

2. Create new Project

In this example, we'll be creating an iOS app.

3250

Selected the project template of your choice.

Select Single View App

3250

Provide a name for the sample app.

Provide a unique name for the sample app

3. Add ASH to your project

3306

Add Nuget Package

3250 3250

Search for AppService.Helpers

4. Add Azure SQLite Store Nuget Package

3250

Add Azure SQLite Store Nuget Package (ASH depends on this).

4. Initialize Azure

3306

Add the following to the AppDelegate FinishedLaunching method.

Microsoft.WindowsAzure.MobileServices.CurrentPlatform.Init();
SQLitePCL.CurrentPlatform.Init();

Initialize ASH

Now we're reading to initialize ASH and register our models. If you're not yet created your models, you'll want to read through our models and object docs.

var client = new EasyMobileServiceClient();
client.Initialize("YOUR_AZURE_URL_GOES_HERE");

//Register our objects
client.RegisterTable<ToDo>();
client.RegisterTable<User>();
client.FinalizeSchema();

var Todos = new ConnectedObservableCollection<ToDo>(client.Table<ToDo>());
var Users = new ConnectedObservableCollection<User>(client.Table<User>());