We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

iOS (System.NullReferenceException) and Android gives error when clicking increment or decrement button on SfNumericUpDown

Hi,

I get aNullReferenceException error on iOS when I which I cannot reproduce in a sample. I also get the error on Android, but I cannot see the details. Here is the StackTrace image of error on iOS.

And here is the image of my code:

 

I tested a few things,

  1. When I remove the Value binding, I don't get the error.
  2. So, in order to test if there are any problems in my code, caused by the PaidQuantity field change, I have added an Entry and also set the binding to PaidQuantity. And updated the value using the Entry, I didn't get any error from my code.
So, that's all the clue I can give unfortunately.

Thanks in advance,

Sinan

18 Replies

OS Osman Sinan Guven December 6, 2022 06:17 AM UTC

New information :)


I am trying to find the error by eliminating code step by step :) And I see that there is a property that I call RaisePropertyChanged on, when the field that that is bound to the SfNumericUpDown (Model.PaidQuantity) is changed . When I comment it out, I don't  get the error. 

However, if there was a specific problem with this code, I would also get the same error, when I bound the Entry field to the same field, as I explained above. 

I also recorded a video to showcase the problem but apparently it is not supported.



ET Eswaran Thirugnanasambandam Syncfusion Team December 6, 2022 07:03 PM UTC

With the provided call stack, we are not able to reproduce the reported problem “NullReferenceException error on iOS” in the iOS platform, so we have added the possible fix for this problem using the provided call stack and the fix is included in our upcoming weekly NuGet which is expected to be rolled out on December 13, 2022. We appreciate your patience until then.


We prepared a sample with the provided code snippet and checked the reported problem “Android gives error when clicking increment or decrement button on SfNumericUpDown”. But we are unable to reproduce the problem in our side. Please get the tested sample from the below attachment.


If you still face any problem, please revert us by modifying the sample based on your application scenario. This will allow us to assist you with a better solution as soon as possible.


Attachment: NumericUpDown_Sample_8f1c59e2.zip


OS Osman Sinan Guven December 7, 2022 02:59 PM UTC

Thanks Thirugnanasambandam,

I hope the upcoming fix works.



OS Osman Sinan Guven replied to Osman Sinan Guven December 13, 2022 05:24 PM UTC

Hi Thirugnanasambandam


Today, I have upgraded the NuGet packages to version 20.3.0.61. However, unfortunately the problem is still appears.


Sinan



OS Osman Sinan Guven December 14, 2022 04:14 AM UTC

Hi Thirugnanasambandam,

On Android, there was this TypeManager.cs opening option when the error occurred, which I didn't notice before. When I opened it I got more detail about the error. I am sending you those details.

1 - System.NotSupportedException

Error Message: 

Unable to activate instance of type Syncfusion.XForms.Android.Border.SfBorderRenderer from native handle 0x7fc5303428 (key_handle 0x97e4ed4).