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).


Hope these details help you to find the bug.


Sinan



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

Thirugnanasambandam, 

I wanted to send more detail (stack trace file and additional images) in one submission, but I couldn't submit them in one reply: I always got "Forum reply submission was unsuccessful" message. Even now, when trying to send more details with images, 

Also, I couldn't upload the stack traces as .txt or .png files (It says file type is not allowed): I don't understand which files are supported to upload.


Sinan



OS Osman Sinan Guven replied to Osman Sinan Guven December 14, 2022 05:54 AM UTC

Hi Thirugnanasambandam,


I have uploaded the files which I couldn't upload previously in zip format.

I hope they will be useful.


Sinan


Attachment: sfNumericUpDownError_9c26489a.zip


VV Vijayakumar Viswanathan Syncfusion Team December 15, 2022 04:12 PM UTC

Hi Osman,

Currently, we are validating the reported query and we will let you know the details on December 19, 2022. We appreciate your patience until then.

 

Regards

Vijayakumar V



ET Eswaran Thirugnanasambandam Syncfusion Team December 15, 2022 04:36 PM UTC

Hi Osman,


Query: NullReferenceException error on iOS

Sorry for the inconvenience. Due to some technical issues, we are unable to include the possible fix in the current weekly release and it will be included in next week's release, which is expected to be rolled out on next week. We appreciate your patience until then. If you need a fix, please let us know and we will share it as a custom patch.


Regards,

Eswaran



ET Eswaran Thirugnanasambandam Syncfusion Team December 15, 2022 07:00 PM UTC

Hi Osman,


Query: NullReferenceException error on iOS

With the provided replication video, we also tried to replicate the reported problem. But we are unable to replicate it from side. Please get the tested sample and video 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.


Regards,

Eswaran


Attachment: NumericUpDown_Sample_(1)_b111549c.zip


VV Vijayakumar Viswanathan Syncfusion Team December 16, 2022 11:08 AM UTC

Hi Osman,

 

Query: Android gives an error when clicking the increment or decrement button on SfNumericUpDown

 

We couldn't able to reproduce the reported issue in Android using the stack trace since it was generic and doesn't occur in SfNumericUpDown. 
We request you to share your issue reproducing sample with replication steps.  It will help us to investigate further and share the details earlier.

 

Thanks,

Vijayakumar



ET Eswaran Thirugnanasambandam Syncfusion Team December 21, 2022 03:53 AM UTC

Hi Osman,


Query: NullReferenceException error on iOS

Due to the 2022 Volume 4 Main Release plan, the current weekly release is postponed to next week. So, we will include the possible fix in the upcoming weekly release. If you need the fix immediately, please let us know, and we will share it as a custom patch. We appreciate your patience until then.


Regards,

Eswaran



ET Eswaran Thirugnanasambandam Syncfusion Team December 29, 2022 05:20 AM UTC

Hi Osman,


Query: NullReferenceException error on iOS


We have added the possible fix for the reported problem " NullReferenceException error on iOS.” and the fix is included in our weekly NuGet of December 28, 2022.

NuGet Version: 
v20.4.0.40


We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.


Regards,

Eswaran



OS Osman Sinan Guven January 10, 2023 08:34 PM UTC

Hi Eswaran,


First of all happy new year to all! We applied a workaround to our code until this error gets fixed, and because of Christmas, we couldn't find time to update and test the new packages.


Today, we have updated the packages to version 20.4.0.43, but unfortunately, we still get the same error. However, this time we have a detailed Stack Trace of the error on iOS.



I am pasting the Stack Trace also below:

  at Syncfusion.SfNumericUpDown.iOS.SfNumericUpDown.EnableOrDisableUpDownButtons () [0x001a2] in <d40ccb89acdc4b4e9ca930ddc0e8fb29>:0
  at Syncfusion.SfNumericUpDown.iOS.SfNumericUpDown.IncrementButtonClicked (Syncfusion.SfNumericUpDown.iOS.UserAction userAction) [0x000cc] in <d40ccb89acdc4b4e9ca930ddc0e8fb29>:0
  at Syncfusion.SfNumericUpDown.iOS.SfNumericUpDown.DownButton (System.Object sender, System.EventArgs e) [0x00094] in <d40ccb89acdc4b4e9ca930ddc0e8fb29>:0
  at UIKit.UIControlEventProxy.Activated () [0x00004] in /Library/Frameworks/Xamarin.iOS.framework/Versions/16.1.1.27/src/Xamarin.iOS/UIKit/UIControl.cs:38
--- End of stack trace from previous location where exception was thrown ---


  at (wrapper managed-to-native) UIKit.UIApplication.xamarin_UIApplicationMain(int,string[],intptr,intptr,intptr&)
  at UIKit.UIApplication.UIApplicationMain (System.Int32 argc, System.String[] argv, System.IntPtr principalClassName, System.IntPtr delegateClassName) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/16.1.1.27/src/Xamarin.iOS/UIKit/UIApplication.cs:57
  at UIKit.UIApplication.Main (System.String[] args, System.Type principalClass, System.Type delegateClass) [0x0003b] in /Library/Frameworks/Xamarin.iOS.framework/Versions/16.1.1.27/src/Xamarin.iOS/UIKit/UIApplication.cs:92
  at Acinocist.iOS.Application.Main (System.String[] args) [0x00001] in /Users/ipekguven/Documents/Projects/acino/acinocist-mobile-dev/Acinocist.iOS/Main.cs:13


Hope this will help you to detect the error.


Regards,

Sinan



ET Eswaran Thirugnanasambandam Syncfusion Team January 11, 2023 01:32 PM UTC

We have added the possible fix for the reported problem “NullReferenceException is thrown when clicking increment or decrement button”. Please find the patch for this issue fix with the version of 20.4.0.38 version. Can you use the below patch to test the fix, and please confirm the reported problem was resolved?


The patch and NuGet for the fix can be downloaded from the below link.


Please find the patch setup from the below location:

https://syncfusion.com/Installs/support/patch/20.4.0.38/252936/F179268/SyncfusionPatch_20.4.0.38_252936_1112023072744261_F179268.exe


(OR)

Please find the patch assemblies alone from the below location:

https://syncfusion.com/Installs/support/patch/20.4.0.38/252936/F179268/SyncfusionPatch_20.4.0.38_252936_1112023072744261_F179268.zip


(OR)

Please find the NuGet from the below location:

https://syncfusion.com/Installs/support/patch/20.4.0.38/252936/F179268/SyncfusionNuget_20.4.0.38_252936_1112023072744261_F179268.zip


Assembly Version: v20.4.0.38


Disclaimer:

Please note that we have created this patch for version 20.4.0.38 specifically, to resolve the issue reported in this ticket. If you have received other patches for the same version for other products, please apply all patches in the order received.


Note: Please clear the NuGet cache, before using the latest one.

https://www.syncfusion.com/kb/6987/how-to-clear-nuget-cache  


Disclaimer: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization


If you still face any problem, can you revert us by modifying the attached sample based on your scenario, this will help us to provide you with a better solution at the earliest.


Attachment: NumericUpDown_Sample_(2)_44fed82c.zip


OS Osman Sinan Guven January 28, 2023 05:33 PM UTC

Hi Eswaran,


Sorry for the late reply. Unfortunately, the patch you provided did not work. I again got the same error from the EnableOrDisableUpDownButtons method. 


We have been trying to overcome this error by sacrificing the proper modeling of our classes. And I believe we have been patient enough for the last two months. 


We are anxiously waiting for you to fix this error.


Sinan



VO Vishal Omprasad Syncfusion Team January 30, 2023 01:20 PM UTC

Currently, our development team is validating the issue at the source level and we will inform you further details on or before January 31, 2023.



ET Eswaran Thirugnanasambandam Syncfusion Team January 31, 2023 11:11 AM UTC

We suspect that the problem occurs due to the referring of old NuGet Cache. So, we recommend trying to clear your system cache. Please follow the below steps to remove the old cache NuGet and check your application with the shared custom patch again.


1.Uninstall the syncfusion NuGets installed in your application.

2.Clear your application NuGet cache using the KB https://www.syncfusion.com/kb/6987 

3.Clean your application.

4.Install the required Syncfusion latest NuGet to your application.

5.Check the reported problem.


Please send us the following information if you continue to encounter the same issue.

• Include the issue reproducing video together with a modified sample depending on your application scenario.

•  Share any sample code snippet.

• Your usage of our control, its goals, and any customizations you made to it.


Loader.
Up arrow icon