Forcing forms to be declared & constructed as opposed to frm.Show
Posted on 2006-05-01
Is there a way to force declaration of a form, rather than going Form.Show?
What I mean is that if someone types in code like this:
I would like either an exception to be raised or come up with build error because it has to be instantiated first..
Rather, I would like to force forms to be declared and constructed so that code is more maintainable, and unseen errors are avoided.
Dim frm as frmForm = New frmForm(var1, var2, ...)
Is there a way to do this?