Forum Xamarin.Android

Error inflating class fragment

Hi, Anyone have running example how to use Google Maps in Android App.. I need just basic code. I have tried almost all examples available on forum and other places, I am only getting this Error.

I am using VS 2013
xamarin.Android.SDK 5.0
Google Map V2

But no success...


  • KhurramShaikhKhurramShaikh USMember ✭✭
    edited March 2016

    I am running Xamarin Trail account..

    and code myClass :

    using Android.App;
    using Android.Widget;
    using Android.OS;
    using Android.Gms.Maps;

    namespace GoogleMapTest
    [Activity (Label = "GoogleMapTest", MainLauncher = true, Icon = "@mipmap/icon")]
    public class GoogleMapActivity : Android.Support.V4.App.FragmentActivity
    protected override void OnCreate(Bundle bundle)
    var fragTx = SupportFragmentManager.BeginTransaction();
    var mapFragment = Android.Gms.Maps.SupportMapFragment.NewInstance();
    fragTx.Add(Resource.Id.mapView, mapFragment, "mapView");

    xml :

    <?xml version="1.0" encoding="utf-8"?>

Sign In or Register to comment.