Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

where to start

Status
Not open for further replies.

tebathe3

Programmer
Jan 17, 2004
89
US
I work for a law firm and it seems everything here is always last minute. I'm still learning VB.Net and with the time constraints, I know my code needs improving! I would like to take one of my existing projects and recode it in a more object-oriented way. The only thing is I don't know where to start. The project is a budget for our IT department. All it basically does is it grabs info from SQL and displays it in a datagrid (budgeted item, price, date, etc). They can also delete records and add new records. There are various "reports" which display different records in a datagrid as well. I'm not sure what would be considered an object here when it seems mostly data driven....
 
Well, I'm not familiar with VB, but I know C++ which is also object oriented.

Anyway, what I'd do is make the budget an object. Then give it the properties item, price, data, etc. That's how I'd go about it in C++ anyway.

But, I'm not the most experienced, so take what I say with a grain of salt.

--------------------------------------
Code:
//Program to tick off my sister
Programming is officialy a life skill

I have no idea what MIS means
 
Here is some advice,
When developing anything oo, try to design and code it in a manner where the UI is not involved in the picture what so ever.

that simple principal will lead you in a direction only few are able to venture. Way back, I use to write apps where I would drag and drop some controls onto a form and then start connecting everything with code-behind...What a big mistake.

start off by not even thinking about UI code at all. Employ the 4 basic seperations of layered architecture.

1. UI Layer
2. Application
3. Domain Model
4. Infastructure


Ignore #1 for new apps, and start with the domain model first.


 
If you are using VB.NET, you will make your life a lot easier if you use NUnit for unit testing. This will enable you to write the Domain Model first, as suggested by EdwardJS, and you can build a suite of test scripts which will allow you to run it independant of the UI. You can actually develop the whole application totally independant of the UI, and just plug it in at the end. I would also recommend doing some reading up on Test Driven Development.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top