Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error inflating class com.airbnb.lottie.LottieAnimationView - Xamarin.Android #954

Closed
luismts opened this issue Sep 19, 2018 · 1 comment

Comments

@luismts
Copy link

luismts commented Sep 19, 2018

I have downloaded the json file from the Lottie page and add it in Assets Folder as an 'AndroidAsset'. And I have this code:

<LinearLayout  xmlns:android="http://schemas.android.com/apk/res/android"
	                xmlns:app="http://schemas.android.com/apk/res-auto"
			android:orientation="vertical"
			android:layout_width="match_parent"
			android:layout_height="match_parent" >

<com.airbnb.lottie.LottieAnimationView
        android:id="@+id/animation_view"
        android:layout_width="fill_parent"
        android:layout_height="28dp"
        android:layout_marginLeft="32dp"
        app:lottie_fileName="loading.json"
        app:lottie_autoPlay="true"
	android:layout_gravity="end" />

</LinearLayout >

In my activity I have this:

 protected override void OnCreate(Bundle savedInstanceState)
 {
           
               base.OnCreate(savedInstanceState);
               SetContentView(Resource.Layout.Splash);

               var animationView = FindViewById<LottieAnimationView>(Resource.Id.animation_view);
               animationView.AddAnimatorListener(this);
          
}

Message:

Binary XML file line #1: Binary XML file line #1: Error inflating class com.airbnb.lottie.LottieAnimationView

Package: Com.Airbnb.Android.Lottie
Version: 2.6.0

@gpeal
Copy link
Collaborator

gpeal commented Sep 24, 2018

@luismts We don't officially support Xamarin so you'll have to debug this one on your own. Sorry.

@gpeal gpeal closed this as completed Sep 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants