Click here to Skip to main content
15,895,142 members
Everything / N-Tier

N-Tier

N-Tier

Great Reads

by Roger C Moore
A guide to constructing an application using Expression Blend and Silverlight for the front-end which obtains data from a WCF service and SQL Server back-end
by alex_lviv
In this article, I will try to describe my vision on creation of simple 3-layer application based on .NET technologies.
by mbarbac
Implementing the Repository and Unit of Work Patterns dynamically using Kerosene ORM
by Shuqian Ying
Service based, multi-application, post ASP.NET 4.0 asynchronous custom membership stores for ASP.NET Identity 2.0 with a hierarchical role system.

Latest Articles

by Zebedee Mason
Software for automatically constructing architecture diagrams and metrics from source code and .NET assemblies is presented. Examples for Visual C++, Python, the Linux kernel, Boost and .NET are discussed.
by alex_lviv
In this article, I will try to describe my vision on creation of simple 3-layer application based on .NET technologies.
by Roger C Moore
A guide to constructing an application using Expression Blend and Silverlight for the front-end which obtains data from a WCF service and SQL Server back-end

All Articles

Sort by Score

N-Tier 

20 Dec 2014 by Roger C Moore
A guide to constructing an application using Expression Blend and Silverlight for the front-end which obtains data from a WCF service and SQL Server back-end
9 Jul 2011 by thatraja
You can do that in following waysCheck if duplicateCreate a method to check the username is already exists in databasepublic bool IsUsernameExists(string strUsername){ //Check the Username is exists in database Ex Query like SELECT * FROM Table WHERE...
9 Jul 2011 by Wonde Tadesse
You can do it in both ways. However if you ask me which one I prefer, I would go implementing in BLL. It is not as such good way of implement such kind of validation in DB level. One draw back is propagating the exception from DAL to BLL and then to UI is one step down than propagating from BLL...
23 May 2012 by Rahul Rajat Singh
Here are two application developed using n-tier architectureYaBlogEngine - A Tiny Blog Engine written in ASP.NET/C#[^]YaMessaging - A simple e-mail like messaging application[^]The first one will even explain about the n-tier architecture and how it is designed and developed that way
12 Jul 2011 by BobJanova
Generally I would put things like this in the business logic layer – after all, it is business logic. However, in the special case of unique constraints on what is presumably a table key, simply setting the primary key (or, if it's not the key column, a unique constraint) on the table will...
12 Feb 2012 by CDP1802
No, it's better not to do that. Inheritance creates a far too strong dependence between the application logic and the data access logic. Just try to estimate the work involved when you have to rewrite the data access classes when migrating to another database. Instead, the DAOs should expose an...
23 May 2012 by Sandeep Mewara
To understand about n-tier, read about 3 tier here and see how it works:Create a class library - BusinessLogic (2nd layer)Create a class library - DataAccess (3rd layer)Now, from your UI (1st layer), use the object model and pass on to BusinessLogic project class. This class is a...
6 Apr 2014 by Abhinav S
I would recommend grouping items from a functional perspective. For eg. all authentication related items together, all database loading related items together and so on.
7 Jan 2015 by Kornfeld Eliyahu Peter
You gave almost no information on how your application will be used - and that's the key for such a decision you ask for here...In any case I would not advise to pre-load data. If you have huge data it will demand huge memory to contain it, and that should be a waste. If your data is small it...
7 Jan 2015 by CHill60
I agree with Kornfeld Eliyahu Peter - don't pre-load, load data as you need it.I'd be a little concerned if a user was dealing with hundreds of records "at a time" in a tax system but I think that is just me misunderstanding your requirements. However it sounds like you will definitely need...
23 Oct 2015 by alex_lviv
In this article, I will try to describe my vision on creation of simple 3-layer application based on .NET technologies.
21 Oct 2015 by Snesh Prajapati
MVVM is a UI layer pattern so obviously must be used in UI layer. As you have BL and DL layer too, In your ViewModel classes of MVVM, you should be using your exiting Models and BL code. And per 3 layer architecture BL would be using DL. For more have a look on...
9 Jul 2011 by mahraja
Hi can anyone tell me that in a 3tier win application, policies like 'avoid inserting duplicate username' should be implemented in the BLL, or in database (as stored procedures) ?
9 Jul 2011 by Mr.Sourav.Maitra
Firstly, do you want to use any built-in tool? Nextly, if you want a simple validation, then YES, surely that can be done in BLL. Put a simple validation by checking the Data Set you have on that moment and run validation block or function. Stored Procedure can also be used and in that case...
12 Jul 2011 by mahraja
thanks, so if I do that in BLL, it reduces one level of propagating exceptions, but also it needs to refer to database twice, first to see if it exists,next insert the record. so which one is preferred?!
24 Sep 2012 by Adam197
Need some advice on a software engineering project that deals with large amounts of File I/O & file manipulation. Current system is written in Visual FoxPro 9 with a SQL Server 2008 database. The compiled application sits on an application server that is accessed via end users across a LAN. ...
24 Sep 2012 by Mehdi Gholam
The "n-tier" architecture originally refered to the breaking of the application into physically separate services on different machines where n being more than 3 (UI, BL, DAL) usually multiple business logic machines.Today this is generally understood as breaking the application into...
21 Oct 2012 by RuanSmit
helloi am making a wcf service program with n tier app (dataaccess tier, WCF, Presentation(asp.net))C#i have a page where you can modify a record but i am directly connected to the database and im not using a dataset. On this page there are 3 texboxes to modify the users. I want to...
21 Oct 2012 by Allan Chong
It will be best to use LINQ to SQL where you map objects to your database relational tablesThen using Operation Contracts you can modify your objects by posting a service call to your WCF services, in your concrete implementation, modify your objects using data contextThe navigation is...
28 Oct 2012 by I.explore.code
The approach I follow is I have 4 layers: UI, BLL, Objects and DAL. UI layer references BLL and Objects layers, BLL references Objects and DAL layers and DAL references Objects layer. Now, this Objects layer is where you create classes that represent objects like Product, Customer etc and...
28 Oct 2012 by Satyendra Kumar(Analyst Programmer)
Hi bro,As you are new to .Net you have asked good question. Here is answer for your question step by step:Step 1: Create a new class library project for your Data Access Layer.Stet 2 : Add a new class library project to your solution and name it like ModalLayer. Now put your modal...
28 Dec 2012 by Suwani De Silva
I know this is a simple question and I am yet a newbie. I want to return data by joning 2 tables. "Products" table and "ProductCategory" Table.In my DAL I have a "Products" class and also a "ProductCategory" class. So do I have to create a new class that has both properties of the...
28 Dec 2012 by Oleksandr Kulchytskyi
Why so complicated ?? You can easily be bounded only with 2 tables.As far as i understood every products has it's own Product category, doesn't it??In case of YES, accordingly you must inject additional property to your's ProductCategory like List Products.Otherwise, in case where...
8 Jan 2013 by testing450
Hi alli find a complete exemple with N-tier architecture + MVC2 (C# code) -Sql Data Base (simple=one table) -DAL(with entity Framework) -Business layer -(service layer) -Presentation Layer With MVC2 (how to make a model and controller: show , insert,...
23 Jan 2013 by AhmedYehiaK
Hi Everyone :),I have a ERP System and i used 3-Tier Architecture then i want to use Crystal reports in my system but i don't know the best way to work with crystal reports in N-Tier ArchitectureWhere i can but the reports physical files?? In which tier??How i can design report...
3 Feb 2013 by Abhinav S
For unit testing the BLL, you can always consider using the Microsoft Visual Studio Testing Framework or a third party like Nunint.For a mocking framework, you can consider using Moles[^].
8 Feb 2013 by AhmedYehiaK
Hi all :)I'm new in reporting service so i'm very confused about interactions between application designed in 3-Tier architecture and reporting service reports How i can dealing with reports??What is the best practice in 3-Tier and reporting service??What about report server??Where...
9 Feb 2013 by Vyacheslav Voronenko
Several points(1)As you can consume SSRS as a webservice reference, you can create your business logic service than encapsulates working with the reports. You can get the EMF/PDF ..etc representation of the report using webservices and deal with it in your code. I really do not see any...
7 May 2013 by Member 9339684
I'm fairly new to c#, asp.net and coding in general, and have been following examples online in order to learn. So far so good, well...up until now.This is the part I'm most concerned about...In the codebehind, I've tried to set the datasource for the grid based on a method in my...
9 May 2013 by Member 9339684
i've been stuck on how to do two insertions in one button click event. what i am trying to do is one insertion, then call the newly inserted id value so that i can insert it into another table using a different method.so basically:button click - call bll and bo - send data to dal and...
9 May 2013 by R. Giskard Reventlov
Can't you do both insertions from the same stored procedure? That way you only need one trip to the database and let the stored procedure handle everything.You're already getting the newly created key: use that to insert the new record in another table.If you do go this way I'd also wrap...
16 Jul 2013 by ♥…ЯҠ…♥
Hi Friends,I am using N-Tier architecture in my application.That consists of MVC web application, proxy project, WCF service project, business layer project, data layer project.I am logging the application activity through Log4Net framework.Now logging is working for MVC Web...
16 Jul 2013 by praks_1
Hi,see this link:http://sadi02.wordpress.com/2008/06/29/log4net-tutorial-in-c-net-how-can-i-show-log-in-a-file/[^]And u don't have to copy .xml file to all project u can do other way round also.
18 Jul 2013 by ♥…ЯҠ…♥
Hi Friends, I solved this by creating separate project called log4netwrapper to log the application.I designed a class to read the log4net config file then, i wrote a class for different debug levels.Now I referenced the log4netwrapper dll to all the layer and I added configuration to...
30 Jul 2013 by Ahmad Abd-Elghany
Reference System.Web
20 Aug 2013 by Bala Selvanayagam
I presume all your processing is done at server level(where the database is and the IIS hosting is) and the workstations are running the web client.Converting this into an N- tier application may help your to distribute across several server - distributing the load and making it faster but...
23 Sep 2013 by Nekoomanesh
i have program 3 tier (in 3 folders DAL,BLL,UI)http://bayanbox.ir/id/5085234522641486493?viewin DAL definition Project Class Library and in project definition .edmx file (Entity Framework)and created folder for Entites (definition class entites in folder).how definition type return...
4 Dec 2013 by Sadique KT
I have following layers in my applicaitonDate Layer (reference to Model)Business Layer(reference to Model ,Data)ModelService(WCF)-(reference to Model,Business Layer)UI (WPF/Silver Light) - Connected via WCF serviceHow do i detect the changed poco entities in an ObservableCollection...
28 Mar 2014 by Mr.VJ
hello see the below linksc# or vb code for thumb impression capturing software using biometrics[^]http://www.vbforums.com/showthread.php?731785-RESOLVED-Biometric-reader[^]http://reddy25.blogspot.in/2009/03/thumb-impression-in-c-net-using.html[^]
6 Apr 2014 by RexGrammer
Should I make a new DAL/BLL class for each table that I want to access in the DB? Or should I just make a generic DAL/BLL class that can handle everything?When I make new ones for each table, the code gets a bit repetitive, but it seems better than making generic classes.
26 Jul 2014 by Member 1310474
Hi All,Am new to N-tier programming and am trying to save an image to the SQL Server database. The field type for the image is varbinary(MAX). In my first attempt I tried to pass the image as an object to the DAL but I got conversion errors. In the second attempt, I am converting the image...
7 Jan 2015 by saleem_deek
I am planning for a project that deals with all kinds of tax for multiple companies and users. I'll be using C# (winforms), layered architecture (UI, DAL, BLL and WebService) and SQL Server.Application will be used by multiple users, where a single user will deal with hundreds (maximum...
17 Feb 2015 by Luis Oliveira 1966
Hello.I wonder how to use Identity ASP.NET on a n-tier design.I have a DLL that provides all the business logic, except authentication and authorization.I would like to implement it using ASP.NET Identity, but I'm finding it difficult to expose the classes of this DLL to the MVC...
17 Feb 2015 by Abhinav S
This is generally done by hosting OWIN files in another virtual directory and exposing these services either through WCF or WebApi.In this case, you want to integrate authentication into the business dll and so you will need to find a mechanism to host the dll as a service.I'm not aware of...
21 Oct 2015 by phil.o
We cannot decently answer to your question, it is too vague.You may need to follow several tutorials around WPF, WCF, MVVM or not, to get a closer idea of what you are going to need, and which tool will be the most useful for you. We cannot do that for you, deciding with which technology you...
24 Oct 2015 by Sergey Alexandrovich Kryukov
Please see: https://en.wikipedia.org/wiki/Multitier_architecture[^].To proceed, you need to start with learning the OS used in each tier, its API and programming, and also some programming languages and technologies.—SA
24 Oct 2015 by Sergey Alexandrovich Kryukov
You are mixing up layered architectures with multi-tier architecture. The are different things. You need to learn about each of them separately.—SA
10 Aug 2016 by F-ES Sitecore
If means the assembly you are registering can't be found.
11 Mar 2014 by mbarbac
Implementing the Repository and Unit of Work Patterns dynamically using Kerosene ORM
4 May 2014 by Shuqian Ying
Service based, multi-application, post ASP.NET 4.0 asynchronous custom membership stores for ASP.NET Identity 2.0 with a hierarchical role system.
4 May 2013 by Ws Hu
This article tries to clarify many basic concepts in N-Tier architecture from all aspects, and also provide some practical tips
11 Nov 2013 by Rahul Rajat Singh
This article describes how to build ASP.NET applications using n-tier architecture.
27 Apr 2011 by Scott Bentley
This article describes why you may want to load an assembly at runtime and how to accomplish it.
10 Jun 2012 by ManojKumar19
This article demonstrates how WF can be consumed as a business layer.
9 Dec 2012 by MarkChimes2
A small utility that generates C# code for each of the layers in an nTiered system.
7 Jul 2016 by Zebedee Mason
Software for automatically constructing architecture diagrams and metrics from source code and .NET assemblies is presented. Examples for Visual C++, Python, the Linux kernel, Boost and .NET are discussed.
13 Feb 2014 by OriginalGriff
Go with the last: the DAL is responsible for data access, so it's the only one which should need to know that connections strings are needed. And it's the one that needs to know where the database server is...the path may be different from the PL or BL because they could be on different...
13 Feb 2014 by Prafulla Sahu
hi I am doing a sample project which has 3 layers like BAL,DAL,PL.BAL which will handle all the Business logic and DAL to perform all database related operations but I am little but confused when I entered into the DAL.To perform database operation we need connectionstring from...
28 Oct 2012 by stuuz
Morning,Only just signed up to this site but I have read a lot of articles previously and found it really useful, so thank you for that!I am currently studying towards my final year of a Computer Science degree, and working on my final project and dissertation. I will be using ASP.NET...
23 Jan 2013 by Mycroft Holmes
If you have a choice DO NOT USE CRYSTAL REPORTS. They have one of the worst reputations for support in the industry. We use SQL Server Reporting Services SSRS but there are a number of better products around.It depends if you want to embed the reports in your application or use a report...
3 Feb 2013 by stuuz
Hey,I've posted about this application before and had some good responses, so hopefully you guys can help again.I'm currently undertaking my final year of a Computer Science degree in the UK, and building an ASP.NET Web Forms CMS with an E-Commerce module as my final project.I'm...
3 Feb 2013 by Kishor Deshpande
Hi,MSTest comes with Visual studio which is testing framework.Now, when you think about isolation framework to remove external dependencies, most of the developers use Rhino Mocks.If you really want to learn how you can write Unit tests for your BAL code without changing it to OR/M,The...
10 Aug 2016 by The Praveen Singh
Try adding the following runtime assembly bindings:
10 Aug 2016 by misaqyrn9677
No Entity Framework provider found for the ADO.NET provider with invariant name 'System.Data.SqlClient'. Make sure the provider is registered in the 'entityFramework' section of the application config file.See http://go.microsoft.com/fwlink/?LinkId=260882 for more information."Iam Using...
8 Jan 2013 by Christian Graus
MVC2 is rubbish. Don't use it. MVC is up to 4, but 3 is good. You're asking for someone to give you a complete project, I suggest rentacoder, you'll need to pay someone to do that.
6 Nov 2013 by thatraja
I suggest you to go with WPF-Silverlight instead of WPF-ASP.NET. Because of similaries like XAML, MVVM, etc., So it'll be easy for you as you could use the same code for two projects. Check theseBuilding WPF and Silverlight Applications with a Single Code Base Using Prism[^]Contrasting...
6 Nov 2013 by Sadique KT
I am planning to create an WPF & ASP.NET application using Entity Framework 5 or 6 with WCF in Ntier architecture..(T want the same application in desktop n web with different databases sql n oracle so if there is better way to do the same in some other manner please suggest ...)Or Any...
9 Jan 2013 by testing450
Christian Graus =i find the "how to" -Passing information between layers DAL,BLL,MVC (C# Class)-why don't use RAD (MVC EF) solution?
23 May 2012 by eyecondeveloper
help needed in this with coding please.
21 Oct 2015 by 1234ctk
I need to do a project with 3-tieras I understand the 3 tier architecture work like that:I have the view-the UI of the user,I have the BLL that have the business logic and the DAL+Model-(I want to use in entity framework)-these three are different projects on the same solution and for...
30 May 2019 by Rakesh Katanguri
Hi All,I have a web application, currently we are storing the user details.Now we wants to store the Thumb Impressions of the users also, for the unique data maintenance. So, what is the procedure to store these info and how can i retrieve this data to compare(to avoid the duplicates). How...
12 Feb 2012 by abi1988
Is that a better way to inherit the Data Access Layer(DAL) in Business Logic Layer(BLL) instead of creating an object of DAL in BLL in any Object oriented language? However the DAL uses only protected methods & properties so that it is not 'visible' to other layers. Is this breaking n-tier...
30 Jul 2013 by Ahmad Abd-Elghany
i cant reference the membership provider in my BLL ! i can't find :using System.web.security and i don't know how to reference it to the BLL, as its deal with its own DAL i know i don't need to use it with my DAL.but how can i use it with in my Tier project
20 Aug 2013 by Prathap S V
Hi All, we have developed a web application using 2 tier architecture since the number of users are less than 30, now we need to deploy the same application to another client where the number of users are more than 300, please advise, I think may be converting this 2 tier to N-tier may be a good...
4 Dec 2013 by Mycroft Holmes
I was going to be helpful right up until I saw that you are using EF. My short answer would be that you don't, you have to implement INotifyPropertyCahnged in your model. We reference the model project from both the WCF and the UI projects.
13 Feb 2014 by Gitanjali Singh
Refer:http://stackoverflow.c...
25 Jun 2014 by Christof Senn
You might be interested in using the open source N-Tier Entity Framework[^] which uses Entity Framework on server-side and generates the entire infrastructure for building an n-tier architecture based on WCF including an EF-like API on client-side for both, Silverlight and .NET
24 Oct 2015 by Patrice T
Quote:How can I do that?Can't help you because you didn't give informations.Start studying documentation of 3-tier framework, search again on Google for examples ang tutorials, ask on forums of users.
12 Aug 2016 by misaqyrn9677
Can Fix It Just All Layer Must One Version Net FrameWork