G
Guest
I'm facing the same problem as many (according to google), i.e. if I close a form (Me.close) and later on I try to reuse it, sometimes (but not always) I get a 'ObjectDispossedException'.
I tried to use Hide instead of Close, but apparently the parent form does not regain control. After calling Me.Hide(), the screen displays the windows logo, etc. What I want to happen is that the parent form gets the focus again - as if I had closed the child form, except that I don't want to dispose it, just don't display it.
Any hints? What's the correct way to have two forms, and the first one being able to display the second one as often as needed, without creating a new instance each time?
Thanks.
I tried to use Hide instead of Close, but apparently the parent form does not regain control. After calling Me.Hide(), the screen displays the windows logo, etc. What I want to happen is that the parent form gets the focus again - as if I had closed the child form, except that I don't want to dispose it, just don't display it.
Any hints? What's the correct way to have two forms, and the first one being able to display the second one as often as needed, without creating a new instance each time?
Thanks.