Nanji Mange
Nanji Mange

Reputation: 2285

How to submit crash report to Microsoft App Center for Xamarin.Forms?

I want to submit crash report to Microsoft App Center for my project which is created in Xamarin.Forms.

Can anybody please suggest a link or steps where I can follow and integrate required steps in my project? I also want to test.

Please guide.

Upvotes: 0

Views: 365

Answers (2)

MShah
MShah

Reputation: 1267

Please refer the detailed information here: App center for Xamarin

Steps are:

  1. You need to create 3 apps in App Center – one for each OS.You need to select Xamarin as the platform for Android and iOS applications and obtain App secret

  2. Install Microsoft.AppCenter.Analytics and Microsoft.AppCenter.Crashes packages.

  3. Open your App.xaml.cs and write this in OnStart() method:

    AppCenter.Start("ios={Your App Secret};android={Your App Secret}", typeof(Analytics), typeof(Crashes));

Upvotes: 1

Gerald Versluis
Gerald Versluis

Reputation: 34103

Whenever you login to the App Center portal all the information you need is right there. Create an app in the portal, one for Android and one for iOS if you have these platforms.

From there, basically you have to install the NuGet packages and add one initialisation line in your code. Note that you will be provided with the ID for this specific app under step 2. If you have multiple platforms, add the line once and replace the different IDs for each platform.

You will then have basic crash reporting and analytics (if you install both packages). You do not need to do anything extra for it, start your app, start using it and watch data come back to the portal.

Since a little while you can now also track handled exceptions and custom events.

For more information, check out the extensive documentation here: https://learn.microsoft.com/en-us/appcenter/

App Center explanation

Upvotes: 4

Related Questions