Chapter 11. Creating a Mobile Application in Visual Studio

Visual Studio is the tour de force of integrated development environments (IDEs). There is no doubt about that. You as a developer are able to be as versatile as you like by creating applications for a wide range of platforms. One of these platforms is mobile development. Developers are starting to create mobile applications, but don't want to use a different IDE. With Visual Studio 2015, you don't have to. It will allow you to create Android and (now with Xamarin) iOS applications too. This chapter will therefore take a look at the following concepts:

  • Installing Xamarin and other required components
  • Creating an Android Visual Studio project using Apache Cordova
  • Creating an iOS application using Xamarin Forms

Introduction

If you have not heard about Xamarin, we encourage you to do a Google search for this tool. Traditionally, developers needed to use Xcode or NetBeans to create iOS and Android applications. The challenge for developers was that it meant learning a new programming language. If you, for example, created an application that you wanted to deploy to iOS, Android, and Windows, you needed to know Objective-C or Swift, Java, and a .NET language.

This also created additional challenges for development, because it meant having to maintain multiple code bases. If a change was to be made in the Windows version of the application, it also had to be made to the iOS and Android code base. Sometimes companies would manage different development teams for each platform. You can imagine the complications involved in managing a change across multiple teams on multiple platforms. This is especially true if you are dealing with a large code base.

Xamarin solves this problem by allowing .NET developers to use standard .NET libraries to create iOS and Android applications using Visual Studio. You, as a .NET developer, can now use the skills you already have to accomplish this. In a nutshell, you would create a shared library for your applications and then have different facades for the different platforms. A second option is to use Xamarin Forms to create one Visual Studio project and target all three platforms. This makes it very easy for developers to target multiple platforms.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.14.93