Click here to Skip to main content
15,887,596 members
Please Sign up or sign in to vote.
2.33/5 (3 votes)
See more:
I had just designed a Project in 3-tier using VB.Net and SQL Server. I would like to know whether my project is really designed as a 3-tiered architecture? Awaiting your comments eagerly! Thanks in advance!

Presentation Layer(PL):
This contains the form and its controls that are 3 Labels, 3 TextBoxes(TXTBX), 2 Command Buttons(Search and Clear) and 1 DataGridView(DGV) and codes for validation, Grid Initialization, GridDisplay, etc that are written in form.vb file

Business Logic Layer(BLL):
This contains the methods that calls the DAL

Data Access Layer(DAL):
This contains the methods to connect to database.

Object File(OBJFILE):
This contains the Get and Set properties for the variables

Now when I click the Search Button in the PL, the program flow is as follows:-

The DGV is Initialized(setting DGV properties) through a function called DGVInit which lies within the form's .vb file
A new object is instantiated for the OBJFILE at the Base Class level.
The TXTBX values are bound to the object of the OBJFILE.
This object is now passed to a BLL's Search method, 'AgentSearch' as an argument through a function named 'DispDGV' in PL.
This 'AgentSearch' method in BLL calls a method(along with the object as an argument) named as 'Search' in DAL
This Search method in DAL executes a SP and returns the DataReader back to the BLL's 'AgentSearch' method.
The BLL's 'AgentSearch' method in turn returns the DataReader back to the 'DispDGV' method in form's .vb file.
This method assigns the returned DataReader to a DataTable and this DataTable sources out data to the DGV.
I have inserted an illustrated image of my project for the same purpose.

I have also posted the same question in MSDN with an image, that might be useful to visualize the Project. http://social.msdn.microsoft.com/Forums/getfile/349324
Posted

1 solution

You should really worry more about if your customers are happy with what you have done than architecture, that will come in time and more experience.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900