How to structure VB.NET windows forms applications
Posted
by Jon
on Stack Overflow
See other posts from Stack Overflow
or by Jon
Published on 2008-11-05T10:05:03Z
Indexed on
2010/03/18
7:41 UTC
Read the original article
Hit count: 662
What is the best way to structure a VB.NET windows forms application so that code can be reused and the app can be extended easily.
I used to create lots of new forms. This lead to lots of repeated code and forms which did similar things.
Now, for forms which do similar jobs, such as view/edit/delete items from a specific db table, I create a form with the required controls, have the form create an instance of a class with params such as a collection of the controls and a string containing the db table name. Then the individual controls call functions of the class.
Advanced forms will inherit and extend this basic form class.
1) Has there already been work done in this area? 2) Are there books / articles available which discuss the options available on this topic?
Thanks!
© Stack Overflow or respective owner