I am using Xamarin.Forms v2.4.0.38779 and I am facing Null Pointer exception which crashes the application. I had same issue with 2.4.0.18342
System.NullReferenceException: Object reference not set to an instance of an object
I guess, Issue occcured while I have ListView with few rows and I am adding new rows, deleting existing rows and also updating values of row based on values, I get from background thread.
As data comes too frequently, around 100 updates in matter of seconds, It crashes.
FYI, I have ObservationCollection binded to ItemSource of ListView. So I dont manage addition, removal and update myself.
Here is stackttrace:
LabelRenderer.UpdateText ()
LabelRenderer.OnElementPropertyChanged (System.Object sender,System.ComponentModel.PropertyChangedEventArgs e)
(wrapper delegate-invoke) :invoke_void_object_PropertyChangedEventArgs object,System.ComponentModel.PropertyChangedEventArgs)
BindableObject.OnPropertyChanged (System.String propertyName)
Element.OnPropertyChanged (System.String propertyName)
BindableObject.SetValueActual (Xamarin.Forms.BindableProperty property,
Xamarin.Forms.BindableObject+BindablePropertyContext context, System.Object value, System.Boolean currentlyApplying, Xamarin.Forms.Internals.SetValueFlags attributes, System.Boolean silent)
BindableObject.SetValueCore (Xamarin.Forms.BindableProperty property, System.Object value, Xamarin.Forms.Internals.SetValueFlags attributes,
Xamarin.Forms.BindableObject+SetValuePrivateFlags privateAttributes)
BindingExpression.ApplyCore (System.Object sourceObject, Xamarin.Forms.BindableObject target, Xamarin.Forms.BindableProperty property, System.Boolean fromTarget)
BindingExpression.Apply (System.Boolean fromTarget)
BindingExpression+BindingExpressionPart.<PropertyChanged>b__47_0 ()
NSAsyncActionDispatcher.Apply ()
(wrapper managed-to-native) UIKit.UIApplication:UIApplicationMain(int,string[],intptr,intptr)
UIApplication.Main (System.String[] args, System.String principalClassName,System.String delegateClassName)
Application.Main (System.String[] args)
Does anyone has idea on how to resolve this?
FYI, This is not about how to resolve NullPointerException, as Xamarin.Forms code is not own by me. I am using that as third party module.