Forum Xamarin Cross Platform with Xamarin

Design choices for simple cross platform app

Hello there :)

I am a long time C# developer but completely new to app development.
Xamarin seems to be the obvious choice if I want to do cross platform (at least IOS and Android, maybe WinPhone) development.

I would love to get some Input on which technologies/structure is best suited for my app before I start developing.

App needs:

  • Local database storage for a few different data structures (all quite simple, fields, lists of values, options etc.)
  • View / Modifications of this database
  • Server communication, accepting Push Notifications from the server
  • Login System (optional)
  • Localizable
  • Notifications (for local events and for events triggered by a server)

Server needs:

  • Forwarding (the same data structures as in the app) to other Clients
  • Login Management
  • Deployment of huge packages of data structures (same as the ones used in the app database)

So far I identified the TaskyPro sample as a good starting point, which uses a local SQLite database for local storage
and a shared library for Business,DataAccess and Data layers and only the UI implemented in the corresponding
platform solutions.

This is enough for me to get most of the app working if you guys agree that local storage with SQLite is a good solution.

The next step would be concurrency.
There will only ever be 0 - about 5 app instances paired to one another (not all apps connected to a main server).
This is why I want to use local storage, one of the use cases doesnt involve a server at all.
If the user adds pairings to other app instances (on other phones) updates he makes will be pushed to the server
and forwared to the paired devices, which will save the changes to their local database. I want to use a locking system
and user confirmation for concurrency issues. The server will also be used to deploy automatic database updates to
all users (regardless of pairings) and for login purposes (login should be the phone number or name/pwd combo).

Would azure be an appropriate choice or a custom tcp server/client combo?
Are there other design choices I should be aware of before starting this project?

Thanks so much for any input !


  • AdamPAdamP AUUniversity ✭✭✭✭✭

    @MarcusSchebesta - You can have a look at this blog post with the example github project
    *disclaimer that is my blog and example

    SQLite is certainly the way to do local storage, unless its just a simple few settings to store, then I would look at Xamarin Plugins Settings (

    If you need to download large chunks of data you might want to look at External or Internal storage on each platform. By blog post goes into that around day 8 I think.

    I have a blog post about Push Notifications ( using Azure Mobile Services, however I believe someone has now developed a plugin that makes it a bit easier.

    That should get you started but let me know of any design issues you might want to discuss.

  • MarcusSchebestaMarcusSchebesta USMember ✭✭
    edited January 2016

    Thank you so much :)

    That article is extremely helpful.

    I have actually started now. A few decisions I made:

    • Base is a Xamarin Cross Platform Xamarin.Forms Template
    • Shared Library includes all navigation Items (View, ViewModel) and Platform specific code
    • Portable Class Library with Business Logic, Contracts, DataAcess Layer, DataLayer
    • Server Project, a simple TCP/IP Server to handle users, the main non-user specific databases, and for pushing data entities to the user or forward them to other users
    • Server and Platform Solutions reference the PCL, all using SQLite and SQLite Extensions (I used a simple interface to create platform specific sqlite connections, no dependency injection here because I haven't figured out how to do it at the server)
    • Databases will be mirrored on Platform Solutions an synchronized through the server
    • WPF Application for Server and Database Management
    • I also created a custom Logging and Localization System, normal logging will be done locally, events of type Error and Fatal will be pushed to the server and central database. Another Database with language identifier, fieldname and value and a simple wrapper around all literals for translations
    • SQLite Extensions is great to easily represent complex data structures and relationships !

    I'm currently reading up on Xamarin.Forms Dependency stuff and your article about navigation.
    I'm still not sure if I want to use Azure or just my server (simple TCP/IP server using System.Net.Sockets) (which would limit it to the time the app is running I guess, but it's supposed to run in the background anyway so maybe thats not a problem)
    I also decided to use compressed JSON for communication with the server to exchange data entities and do concurrency in the DataAccess Layer

Sign In or Register to comment.