G
Guest
I have a base form with a few controls, some methods, and some properties
that I inherit from to create three different form classes (in a VB.net 2003
solution, in a lib project along with program and deplyoment projects). When
I first wrote this, all worked just fine.
I created a new inherited form (using Add inherited form ...) and
immediately the newly created form plus any existing forms that inherit from
the same base form no longer display but give the error message, "An error
occured while loading the document. Fix the error, and they try loading the
documen again. The error message follows: Object reference not set to an
instance of an object." I assume that the form designer has failed somehow
when attempting to draw the form in the design mode. The newly created form
never displayed at all.
The base form (and others that don't inherit from it), however, display
without error. Removing the newly created inherited form from the project and
deleting it entirely has not fixed the problem; now I get this error with any
of the inheriting forms.
Yet, the application runs just fine. I tried the trick of closing all
[Design] tabs, and also completely restarting VS with no luck. I ran into
this once before and solved it by recreating the base and inherited forms
from scratch, a time-consuming excercise that I don't wish to repeat.
I am able to recreate a form inheritance example in a separate solution with
no problem, as well.
Does anyone have a fix or some ideas of what to look for?
Thanks,
DrJohn
that I inherit from to create three different form classes (in a VB.net 2003
solution, in a lib project along with program and deplyoment projects). When
I first wrote this, all worked just fine.
I created a new inherited form (using Add inherited form ...) and
immediately the newly created form plus any existing forms that inherit from
the same base form no longer display but give the error message, "An error
occured while loading the document. Fix the error, and they try loading the
documen again. The error message follows: Object reference not set to an
instance of an object." I assume that the form designer has failed somehow
when attempting to draw the form in the design mode. The newly created form
never displayed at all.
The base form (and others that don't inherit from it), however, display
without error. Removing the newly created inherited form from the project and
deleting it entirely has not fixed the problem; now I get this error with any
of the inheriting forms.
Yet, the application runs just fine. I tried the trick of closing all
[Design] tabs, and also completely restarting VS with no luck. I ran into
this once before and solved it by recreating the base and inherited forms
from scratch, a time-consuming excercise that I don't wish to repeat.
I am able to recreate a form inheritance example in a separate solution with
no problem, as well.
Does anyone have a fix or some ideas of what to look for?
Thanks,
DrJohn