Opening external applications

In this recipe, we will create and explain all the code that is necessary to open external applications with Intents.

Getting ready

Create a new solution named Intent_Project and open the project of the same name that Xamarin Studio has created for you.

How to do it...

  1. Add the following code in the OnCreate() method to the MainActivity class so that it looks like the following:
    using System; using Android.App; using Android.Content; using Android.Runtime; using Android.Views; using Android.Widget; using Android.OS; namespace intent_project { [Activity (Label = "intent_project", MainLauncher = true)] public class MainActivity : Activity { protected override void OnCreate (Bundle bundle) { base.OnCreate (bundle); var geoUri ...

Get Xamarin Studio for Android Programming: A C# Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.