Xamarin Blog

An open source mobile platform for building Android, iOS, macOS, watchOS, and tvOS apps with .NET.

Fast & Simple Android Location Updates with Google Play services

Starting an Android application that relies on device location can be overwhelming. The classic way of getting location is with Android's core APIs, which have been around for a very long time and can be confusing to use. To simplify this process, we developed the Geolocator plugin, which enables developers to get the location from shared code on iOS, Android, and Windows from a single API. There are times when you may want or need full control over the API, however, and that's where the new Google Play services location APIs come in. These APIs simplify location awareness with multiple sensors on the device to help determine the location of the user. This means that, when using these new APIs, querying for location updates is faster and more accurate and, with the most recent update (11.0.4), it's never been easier to get started.

Exploring Android’s Bottom Navigation View

The debate over whether tabs should go on the top or the bottom of a screen has raged for nearly a decade. Android has always preferred to use tabs as a filtering mechanism on the top of a page, while iOS has used bottom tabs as the main source of navigation. Now, with the addition of the Bottom Navigation View in the Support Design library, Android developers have the choice of where their main navigation comes from in their applications.

Mastering the Android Support Libraries

Android Support Libraries are an essential part to every Android application and you'll find them absolutely everywhere. The Support Libraries offer developers the ability to add the latest and greatest features of Android to their application while maintaining backward compatibility with older versions of Android. As new versions of the Android SDK continue to roll out, so do updates to the Support Libraries; keeping them up-to-date and installing the correct versions is an important (and sometimes frustrating) part of Android development. This blog post will help demystify the Support Libraries and help you upgrade to the latest versions.

Securing Web Requests with TLS 1.2

In my years of development, one thing I've learned for certain is that securing your network requests is an essential part of any mobile application. A few weeks ago one of my own applications stopped working due to a change to a Secure Sockets Layer (SSL) certificate on meetup.com's authentication server, which made me realize the important role Transport Layer Security (TLS) plays in securing app and server requests.

Simplified Android Keystore Signature Discovery

The Android Keystore is at the heart of every Android application. It enables us to sign our applications and ship them to the app store securely, but also holds additional signature information needed for Google Play services and other APIs, such as Facebook. This new extension makes it super simple to get access to everything you need to sign your app!

Consumable In-App Purchases

If you are building a game or application with content that needs to be purchased multiple times, you'll need to integrate consumable in-app purchases (IAPs) into your application. In my previous IAP blog post, I covered the basics of setting up your app for IAP transactions, adding the IAP items to Google Play and iTunes Connect, and introduced you to the In-App Billing Plugin for Xamarin that greatly simplifies the process of adding IAP to your application's code. Today, we'll take a look at consumables and how they offer a slight tweak to the development process.

Integrating In-App Purchases in Mobile Apps

Developers often need to integrate monetization to generate revenue when developing mobile apps. There are several ways to monetize apps, but at some point you may want to introduce In-App Purchases, or IAPs, into your app. IAPs can be used in several ways that could apply to your apps, such as adding features, removing ads, or buying in-game currency. Let's take an in-depth look at IAPs and how to add them to mobile apps.

Round Launcher Icons in Android 7.1

Circular launcher icons have become standard since the introduction of Android Nougat 7.1 and the new Pixel Launcher. Google has even introduced a new API enabling developers to specify a round launcher icon for launchers that support it, which is great if you have strong branding and only want a round icon to show up to match the launcher.

Enhanced Device Logging in Visual Studio

During development we often print out logs, warnings, and errors to the console to help with the debugging process. However, with the complexity of mobile operating systems and applications, we often need to see what's happening on the device or being logged by other parts of the operating system. This is where the iOS and Android device logs come in to help; they've been completely redesigned in the latest version of Xamarin for Visual Studio.