Xamarin.forms Firebase analystics.

shanmugashanmuga Member ✭✭

I have implemented Firebase analytics tool in Xamarin.forms application, and i unable to create custom event

**public partial class FeedPage : ContentPage
IFirebaseAnalytics eventTracker;
public FeedPage()
eventTracker = DependencyService.Get();

    void Handle_Clicked(object sender, System.EventArgs e)  
        eventTracker.SendEvent("Click1");   // Custom event 

This custom event throw the error System.NullReferenceException: 'Object reference not set to an instance of an object.'


  • AlessandroCaliaroAlessandroCaliaro ITMember ✭✭✭✭✭

    Can you explain how have you been able to install the nuget? I have always some errors...

  • shanmugashanmuga Member ✭✭

    okay, Install individually those NuGet packages for Android = Xamarin.Firebase.Analytics.Impl version = 60.1142.1, **iOS =Xamarin.Firebase.iOS.Analytics version 6.0.4 ** Xamarin.Forms = , After successful install, please create interface and followed by class.cs files both android and iOS.

  • AlessandroCaliaroAlessandroCaliaro ITMember ✭✭✭✭✭
Sign In or Register to comment.