Tuesday, 2 October 2007

.Net My.forms collection is not showing some of the forms

My.Forms exposes only a default instance of each of the form classes and it displays only the forms with parameterless constructor. i.e. If the form contains a constructor which has some parameters, this form won't be exposed as part of the My.Forms

The compiler will only generate a parameterless constructor for a form if there is no constructor present at all. This behavior is by design.

No comments: