Cannot access a disposed object - Object name: 'Com.Syncfusion.Calendar.InlineLayout'.

If I select a couple of days on the SfCalendar, go to another page (with a SfDataForm) and press the back button and repeat the process my app crashes. This only happens on Android. Attached is the code for my two Views.

It crashes in the following condition:
     1. When ShowInlineEvents = true and the next page has a SfDataForm on

It doesn't crash when either ShowInlineEvents = false OR SfDataForm is removed OR if I didn't click on any days. 

Here's my application output:

Unhandled Exception:
[mono] System.ObjectDisposedException: Cannot access a disposed object.
[mono] Object name: 'Com.Syncfusion.Calendar.InlineLayout'.
[mono]   at Java.Interop.JniPeerMembers.AssertSelf (Java.Interop.IJavaPeerable self) [0x00029] in <09bf3e262b934ffab2ba01f9fc7fd54d>:0 
[mono]   at Java.Interop.JniPeerMembers+JniInstanceMethods.InvokeVirtualInt32Method (System.String encodedMember, Java.Interop.IJavaPeerable self, Java.Interop.JniArgumentValue* parameters) [0x00000] in <09bf3e262b934ffab2ba01f9fc7fd54d>:0 
[mono]   at Android.Views.ViewGroup.get_ChildCount () [0x0000a] in <25661073a35344a89f215a4cf81af37c>:0 
[mono]   at Com.Syncfusion.Calendar.InlineLayout.Dispose (System.Boolean disposing) [0x0007e] in <141bc1a5d8844d208d96a43459c4663a>:0 
[mono]   at Java.Lang.Object.Finalize () [0x00048] in <25661073a35344a89f215a4cf81af37c>:0 
[mono-rt] [ERROR] FATAL UNHANDLED EXCEPTION: System.ObjectDisposedException: Cannot access a disposed object.
[mono-rt] Object name: 'Com.Syncfusion.Calendar.InlineLayout'.
[mono-rt]   at Java.Interop.JniPeerMembers.AssertSelf (Java.Interop.IJavaPeerable self) [0x00029] in <09bf3e262b934ffab2ba01f9fc7fd54d>:0 
[mono-rt]   at Java.Interop.JniPeerMembers+JniInstanceMethods.InvokeVirtualInt32Method (System.String encodedMember, Java.Interop.IJavaPeerable self, Java.Interop.JniArgumentValue* parameters) [0x00000] in <09bf3e262b934ffab2ba01f9fc7fd54d>:0 
[mono-rt]   at Android.Views.ViewGroup.get_ChildCount () [0x0000a] in <25661073a35344a89f215a4cf81af37c>:0 
[mono-rt]   at Com.Syncfusion.Calendar.InlineLayout.Dispose (System.Boolean disposing) [0x0007e] in <141bc1a5d8844d208d96a43459c4663a>:0 
[mono-rt]   at Java.Lang.Object.Finalize () [0x00048] in <25661073a35344a89f215a4cf81af37c>:0 
[] HostConnection::get() New Host Connection established 0x82b515c0, tid 32605


Attachment: Views_14e4d7bb.zip

17 Replies

VA Vinnalan Aravazhi Syncfusion Team May 24, 2018 10:17 AM UTC

Hi Victor,

Thanks for contacting Syncfusion support.

Query: Select a couple of days on the SfCalendar, go to another page (with a SfDataForm) and press the back button and repeat the process my app crashes on Android.

We have checked the reported issue from our side and we are able to reproduce the reported issue from our side. We will fix the reported issue and fix will be included in our upcoming 2018 volume 2 Sp 1 release, which will be rolled out by the end of June.

Please let us know if you have any other queries.

Regards,
Vinnalan K A.


VI Victor May 24, 2018 11:16 AM UTC

Thank you for the response.

The calendar is a very important feature in our app, so we look forward to the fix.

Regards


VA Vinnalan Aravazhi Syncfusion Team May 25, 2018 10:18 AM UTC

Hi Victor,

Thanks for your update.

A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates.

https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents/

Regards,
Vinnalan K A. 



DA David July 9, 2018 08:37 AM UTC

is fixed? 

Im having the same exact issue :(

Regards,

David.


VR Vigneshkumar Ramasamy Syncfusion Team July 10, 2018 11:52 AM UTC

Hi David,

We are glad to announce that our Essential Studio Volume 2 (v16.2.0.41) is rolled out along with the issue fix of issue “Cannot access a disposed object” and is available for download under the following link.


Link: https://www.syncfusion.com/forums/138315/essential-studio-2018-volume-2-release-v16-2-0-41-is-available-for-download 

Please get in touch with us if you would require any further assistance. 
 
Regard 
Vigneshkumar R 



FL FEDERICA LAZZERI March 12, 2019 12:04 PM UTC

Hi,
I have a similar issue:
I have a standard sfcalendar with no custom template,
if I select one day (with o without events), then change month, then press the back button (to step back on application navigation stack).
the app crash with this same error.

thanks


SP Subburaj Pandian Veluchamy Syncfusion Team March 13, 2019 06:52 AM UTC

Hi Federica, 
 
Based on the provided information, we have checked the reported issue “Throws exception when navigation back from Calendar” in Xamarin.Forms and it is working fine. We have tested by selecting a date in the calendar which has no events, then moving to another month and navigation back to previous page works as expected with our latest update version 16.4.0.52 and above. 
 
Please find the following sample for your reference, 
 
Sample link: CalendarNavigtaion 
 
In the sample, we have loaded Button in the main page and in click event we have moved to Calendar page. 
 
Kindly check the sample and if you still face the same issue please let us know the Calendar update version? If not, please modify the sample based on your scenario and revert us back with the Xamarin.Forms and device configuration details. It will be helpful for us to check on it and provide you the solution.  
 
Regards,
Subburaj Pandian V  



FL FEDERICA LAZZERI March 13, 2019 02:42 PM UTC

Hi,
I tried your example and I confirm the issue.
I am using a standard nexus 5, api 21 emulator.
the only changes I have done to your sample project are:
adding all the cpu architectures and changing the target platform from 9 to 8.1.
How the issue happens:
1) Load the application
2) Press the "calendar" button"
3) in the calendar page click on a date cell with or without events
4) change month while the events panel is opened
5) press the toolbar "back" button

doing these steps your sample will crash





SP Subburaj Pandian Veluchamy Syncfusion Team March 14, 2019 05:57 AM UTC

Hi Federica,  
 
Thank you for the update. 

We can able to replicate the mentioned issue “Throws exception when navigation back from Calendar with Inline opened” in Xamarin.Forms and logged issue report for the same. We will fix this issue and provide you the issue fix patch within three weeks (April 4, 2019). We appreciate your patience until then  
  
You can track the status of this report and contact us for any further inquiries through the following feedback link, 
 
 
Regards,
Subburaj Pandian V 



SP Subburaj Pandian Veluchamy Syncfusion Team March 20, 2019 10:33 AM UTC

Hi Federica, 
 
We are glad to announce that our Essential Studio 2019 Volume 1 Beta Release version 17.1.0.32 is rolled out with the issue fix of “Throws exception when navigation back from Calendar with Inline opened” and is available for download under the following link.  
   
 
Note: Since this NuGet is beta version, please ensure whether you have enabled Show pre-release packages in NuGet Manager, the main release will be expected to be available by end of March 2019. 
  
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,
Subburaj Pandian V  



FL FEDERICA LAZZERI April 30, 2019 03:44 PM UTC

hi,
I updated the component and tested it on your example, linked in the post dated March 13, 2019.
doing the steps mentioned by me in the same day i have the same old error:
System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'Com.Syncfusion.Calendar.InlineLayout'.

it seems that nothing has changed....





DB Dinesh Babu Yadav Syncfusion Team May 1, 2019 06:37 AM UTC

Hi Federica, 
 
Based on the provided information we have checked with the query Throws exception when navigation back from Calendar with Inline opened” with latest SfCalendar (v 17.1.0.43) and it is working fine from our side.

Sample : CalendarAppointment

We suggest you to kindly refer the following link to clear NuGet cache,
 

Please clear the existing NuGet and check with the sample attached above. Kindly revert us if you have any concern.

Regards,
Dinesh Babu Yadav
 
 



FL FEDERICA LAZZERI May 6, 2019 08:22 AM UTC

if you enable the "navigation buttons" and try to change month while the inline panel is open your example app will crash.


SP Subburaj Pandian Veluchamy Syncfusion Team May 7, 2019 08:44 AM UTC

Hi Federica, 
 
Thank you for the update. 
 
We have checked and we can able to replicate the issue “When enabling navigation buttons Throws exception when navigation back from Calendar with Inline opened”. We have fixed the issue and issue fix is in testing phase. We will include the issue fix in our upcoming Volume 1 SP1 release which is expected to be available by mid of May 2019. We appreciate your patience until then. 
 
Regards,
Subburaj Pandian V  



SP Subburaj Pandian Veluchamy Syncfusion Team May 15, 2019 10:22 AM UTC

Hi Federica, 
  
We are glad to announce that our Essential Studio 2019 Volume 1 SP1 Release v17.1.0.47 is rolled out with the issue fix “When enabling navigation buttons Throws exception when navigation back from Calendar with Inline opened” and is available for download under the following link. 
  
  
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,
Subburaj Pandian V    



HL Homero Lara September 23, 2019 12:14 PM UTC

Hi,

It appears that this issue hasn't been fixed. I'm experiencing this same crash on Android with Syncfusion Calendar v17.1.0.53.

I filled out an incident report earlier with additional details. 

Thanks,
Homero


IR Indumathi Ravichandran Syncfusion Team September 24, 2019 10:16 AM UTC

Hi Victor, 
 
Thank you for contacting Syncfusion support. 
 
Based on the provided information we have checked the mentioned exception “Cannot access a disposed object in Calendar” in XForms.Android and we have unable to replicate the issue from end. We have tested by selecting the dates in calendar and Navigating to the page with DataForm and back to the Calendar page and it is working fine as expected. We have prepared sample for the same, 
 
 
 
We have tested with Syncfusion update version 17.3.09 and Xamarin.Forms version 4.1.0.555618. 
 
Tested Device: 
Honor 9N 
 
Please check the sample and let us know if you still facing the same issue? If not, please modify the sample based on your scenario and revert us back with the following details, 
 
·       Device configuration details 
·       Issue reproducing video (if possible) 
 
It will be helpful for us to check on it and provide you the solution at the earliest.   
 
Note: Kindly update Nuget to latest version (17.3.0.9) 
 
Regards, 
Indumathi R 


Loader.
Up arrow icon