Welcome to the Xceed Community Sign in | Join | Help
Community Search  

System.ObjectDisposedException: Cannot access a disposed object

Sort Posts: Previous Next
  •  07-09-2008, 5:04 AM Post no. 13468

    System.ObjectDisposedException: Cannot access a disposed object

    Hi,

    My program is multi-threaded, and there are constantly updates made onto the grid (either by user manually, or by other thread automatically). I got this System.ObjectDisposedException error when I try to close the form. I tried, in my code, to check that the form is not null and is visible before attempting to update the grid on the form. But since my program is multi-threaded, I guess update could be made to the grid at any point. And thus, I could get this error. Can you please suggest a solution to this? I guess I can catch this error in try-catch block as a workaround. But I wonder of a nicer way for this.

    Thanks!

     

  •  07-11-2008, 1:40 PM Post no. 13531 in reply to 13468

    Re: System.ObjectDisposedException: Cannot access a disposed object

    Except verifying the form is still valid from the other threads, we don't see other ways of doing this.


    André
    Software Developer and Tech Support
    Xceed Software Inc.
View as RSS news feed in XML
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2008 Xceed Software Inc.