Learning Xamarin from scratch and delivering a production ready app in 2 weeks

Prashant
4 min readApr 27, 2020

--

This is my real life experience of learning Xamarin from scratch and delivering a production ready app in 2 weeks. The app is not public facing but still has 200+ in-house users and involves use of many native device features.

Here’s some stage setting - I run a small software development company and primarily work on web-based software solutions for corporate clients. Mobile app development is something I have never done before and do not intend to venture into in the foreseeable future.

The app I am going to talk about was a requirement that came from an existing client. I was already engaged with them on multiple projects. The client needed a mobile application for securing a big contract but had a short period of time, around 4 weeks, to develop it. It was not feasible for them to find and evaluate a new vendor and experiment with them. So, they asked me if I can pull this off. Although I was not much interested in mobile app development, but the client had a burning need and I also had some time to spare during those days. So I asked for 2 days to think and get back to them.

Based on the requirement specification document, I compiled a list of features that the app must have (this is not the user requirement, but only the functional feature list from a developer’s point of view):

  1. Camera - Take pictures, show as thumbnails, read as blob.
  2. GPS - Ascertain current co-ordinates. Show a map to pick another location, then read the new co-ordinates
  3. HTTP Client - Send GET/POST requests, some involving large payloads
  4. Local Database Storage - Saving downloaded data, maintaining offline data cache, uploading new data, typically all CRUD operations. Database needs were not merely limited to storing user preferences and logging. Some transactions involved up-to 50K rows of data to be stored, processed and updated. So, real db needs.
  5. Notifications - Receiving push notifications and navigating to certain activity/screen when user taps on the notification.
  6. Signature pad - Showing a white board for touch signature and storing the resulting images as a jpeg.

As you can see, the above list is a modest one and require serious development efforts, not just playing around. I know there are many other advanced APIs not listed here, but even what is here appeared too much to me to begin with.

Anyways, I had to get back to the client, so I started exploring. I was neither willing nor had time to learn Java/Kotlin or even the newer frameworks like React or Flutter. Being a C# .NET developer, my only go-to option was Xamarin. I laid out a clear plan - I will spend 2 days in reading, exploring and experimenting as much as I can and will try to: a) create a user interface with navigation, and b) send/receive http requests. If I can successfully build these two functionalities in this time, I can hope to build the full app.

I was able to do the above two without much trouble in 2 days and agreed to the client for developing the app. However, the way ahead was not going to be that easy. As I dug deeper, I faced many challenges; sometimes I felt like hitting my head on the wall (push notifications). At the same time, I found some ready to use libraries that worked like charm (signature pad). At last, everything came together in time.

Besides the couple of days for pre-work and research, the app was delivered within 2 weeks after I formally signed a contract with my client (I think I should add here that I typically work for 12–14 hrs a day, 5 days a week).

The first release of the app was instantly installed by over 25 field users who tested it rigorously. Over the next 2 weeks, I carried out many performance improvements, fixed a lots of bugs and added some new features. After 1 month, the app was pretty stable and no new bugs and performance issues were reported.

The customer was beyond happy. The project’s VP & company’s CTO called and thanked me personally.

Working on Xamarin was an incredible experience. Having prior knowledge of XAML (in designing front-end of WPF apps), and C# was a great advantage. I would not exaggerate if I say that around 75% of my existing skills were utilized. I tried to utilize Xamarin.Forms as much as possible to stay within the known territory and avoided coding at Android API level as much as possible. I had to get down at that level only for implementing push notifications using Firebase. Phew! That was really mind boggling!

Thanks for reading this far. I really started writing this with an intention to write a series of posts covering each of the features listed above. Therein, I plan to include code snippets, tips, common issues faced and their solutions. Hope to start it soon!

I must acknowledge that the only reason I was able to pull this off is because of the enormous power of sites like Stack Overflow and thousands of those who are willing to share their knowledge to help others. Like mentioned above, some plugins saved hours of work and saved me from reinventing the wheel, therefore, the role of open source development cannot be understated.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Prashant
Prashant

Written by Prashant

Finance guy who fell in love with technology and switched careers in early 30s. Follow me: https://twitter.com/prashantio Business URL: https://runtime.one

Responses (1)

Write a response