Error Unloading Form

  • Thread starter Thread starter Wittaya
  • Start date Start date
W

Wittaya

I am using command Me.Closed()in Event of TreeView
AfterSelect.

This below is Error Message appear.

An unhandled exception of type 'System Object Disposed
Exception' occured in system.windows.forms.dll

Additonal Information : Cannot access a disposed object
named "Treeview".
 
Wittaya said:
I am using command Me.Closed()in Event of TreeView
AfterSelect.

This below is Error Message appear.

An unhandled exception of type 'System Object Disposed
Exception' occured in system.windows.forms.dll

Additonal Information : Cannot access a disposed object
named "Treeview".

I think I remember reading a solution that enabled a timer, fired directly
after the AfterSelect event because you can not close the form in this event
handler (and in other handlers). In the timer's tick event, Me.Close is
called.
 
Herfried,
I thought of that when I had sended it, and then you cannot correct it and
did not know how to correct it and then I saw the message from Armin and
thougth what can I do more.
:-)
Cor.
 
Cor said:
I thought of that when I had sended it, and then you cannot correct it and
did not know how to correct it and then I saw the message from Armin and
thougth what can I do more.

ROFL again.
 
Back
Top