Skip to content
This repository was archived by the owner on Mar 24, 2023. It is now read-only.
This repository was archived by the owner on Mar 24, 2023. It is now read-only.

Xamarin.Forms[Android] app crashing with Annotations  #88

Open
@andreybel

Description

@andreybel

Hi!
I'm trying to implement Mapbox in my Xamarin.Forms app and have a problem.
When i'm adding List of Annotations to Map and restart app, i'm getting Exception:

java.lang.NullPointerException: Attempt to invoke virtual method 'android.graphics.Bitmap$Config android.graphics.Bitmap.getConfig()' on a null object reference

My Annotation:
Annotations.Add(new SymbolAnnotation
{
Coordinates = new LatLng(50.4308233, 30.468171),
Id = Guid.NewGuid().ToString(),
Title = "test point",
SubTitle = "test point description",
IconImage = (ImageSource)"ic_pin8.png", // problem is here
IsDraggable = false
});

NOTE: It doesn't happen during first start, only after OnSleep() - OnResume().
Tell me please, where is my mistake?
Thank's!

P.S. problem detected on Android

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions