What are the pros and cons of using a MDI form? Is there a
better way to use multiple forms within a project? I am very new to VB. Thanks.
Printable View
What are the pros and cons of using a MDI form? Is there a
better way to use multiple forms within a project? I am very new to VB. Thanks.
It debends what you want your project to do, MDI stands for Multiple Document Interface, and it does exactly what it says on the tin, it provides an interface for multiple documents, If you want something like Word, where you can have lots of the same type of form open at once, all inside one big form and you work on the one that's highlighted, then use MDI, if you want lots of different windows open at once use normal forms, MDI is great for word processors and the like but not much good for other things.
I used MDI for an app for creating and tracking work orders. The work order form is my "multiple" document. I also used MDI for another similar app which tracks claims where the claim form was the "multiple" document. Of course, independent forms are also used in both apps for other things.
MDI cuts down on coding for duplicated forms and such.
i only choose MDI interfaces, if it is absolutely neccesary. you can easily end up producing tons of code just to keep track of opened forms, adjusting your MDI form's menu, toolbar and status bar. plus in many cases users find MDI apps complicated to work with.
i normaly try to have as few forms as possible and found outlook-style designs very practical.
but that's only my taste, try both and see what you and your users like more.
best regards
I use MDI for larger Applications that actually require it. Some things, like paintbrush do not necessarily need an MDI. Usually if you're working on a picture, you're only working on one whereas on Word or Excel, you might need a lot.