Asp.net - 3 Tier Application Pattern Suggestion?

Apr 12, 2010

I have attempted to make my first 3 tier application. In the process I have run into one problem I am yet to find an optimal solution for. Basically all my objects use an IFillable interface which forces the implementation of a sub as follows

Public Sub Fill(ByVal Datareader As Data.IDataReader) Implements IFillable.Fill

This sub then expects the Ids from the datareader will be identical to the properties of the object as such.

Me.m_StockID = Datareader.GetGuid(Datareader.GetOrdinal("StockID"))

In the end I end up with a datalayer that looks something like this.

Public Shared Function GetStockByID(ByVal ConnectionString As String, ByVal StockID As Guid) As Stock
Dim res As New Stock
Using sqlConn As New SqlConnection(ConnectionString)[code].....

Mostly this pattern seems to make sense. However my problem is, lets say I want to implement a property for Stock called StockBarcodeList.Under the above mentioned pattern any way I implement this property I will need to pass a connectionstring to it which obviously breaks my attempt at layer separation.how I might be able to solve this problem or am I going about this the completely wrong way? I am deliberately trying to avoid using the dataset in any form.

View 2 Replies


ADVERTISEMENT

Create A TEXTBOX With Auto-suggestion For Windows Based Application?

Jan 21, 2011

I am trying to create a accept User Name in textbox and as additional feature i want to show suggestion to user automatically. For example if user press "J" he names starting with "J" (present in name table ) should be displayed as drop-down.

Can i do it with TEXTBOX or is there any other simple way?

View 1 Replies

Suggestion Request ::: Database Format For Visual Studio Application?

Dec 14, 2011

I am very confused about the database type to be used in my vb.net application. I have been using SSCE database, but for that user has to download and install SSCE, which many of my users do not want. If I use Access, the security issue is very very serious.I have downloaded a few database apps from the internet, which donot require any such thing to be installed and also I see no known database format in the application folder. I wonder what kind of techniques they are using.

View 12 Replies

Build N-Tier Web Application?

Oct 14, 2009

Im trying to build my first N-Tier web application. And it seems like im doing it wrong. Ive been kinda working out of this book, but to me it doesnt seem like the right way to do this. In the book the guy builds User and Data centric objects but everywhere I see ntier everyone is always talking about BLL and DAL ive seen nothign on UC and DC objects.Right now I have Interfaces and serializable structures, user and data centric objects. The data centric object does all the validation and connecting to the db, as well as returns any violated rules, but when I once i started pulling it all together it just doesnt seem right.Ive already wrote a ____ load of code and now am kinda stuck. I dont know if i am doing this right and dont want to continue writing any code if this is all messed up.Ive been reading as much as humanly possible and im still just a little confused. I mean I understand the concepts of seperating the logic into different layers and tiers and all that but as far as my implementation of that I just feel somethings a bit off.

View 3 Replies

Create An N-tier Application?

Dec 12, 2009

I have a solution and I want to divide it up into Business Tier, Data Tier, etc. I think I have to do this by creating a project that contains the data source, another with the forms, etc. Every time I try to add a new project, it literally opens a new project, seperate from the first.

View 1 Replies

VS 2008 Two Tier Application Over The WAN?

Oct 16, 2011

i am on a project of two tier application with VB.NET + SQL server R2. except desk top applications i never done networked applications + i don't know asp.net

i require advise in few areas

(1) is the encryption required

(2) what are the security measures i must take in terms of connection security

(3) how to use the server effectively with out putting much burden through good client end design

(4) any other guide lines / pit falls

(5) should i continue with vb.net or must & should switch over to asp

(6) what should be the minimum configuration of client system,

(7) Preferable is the thin client systems , is it possible to use thin clients

View 7 Replies

What Is 3 Tier Architecture For Windows Application

Oct 21, 2009

Using VB.NET 2008 I want to know what is 3 Tier Architecture for windows application? How to make a code for Inserting, Deleting, Updating in a database using 3 tier architecture.

View 5 Replies

Building A Large Application Using 3 Tier Architecture

Feb 8, 2011

Building a large application using 3 tier architecture in vb.net. Question: I am a vb.net developer. I have developed small and medium size application with 2 tier architecture. Now I am going to develop a large application. I have decided to develop that application using 3 tier architecture. So I studied about 3 tier. Now I know how what is 3 tier and how to develop a simple application. And also I studied about .Net Remoting and Web services. In my project, 7 modules are available. Each module has 3 layers. How can I manage in a Single Solution?

View 1 Replies

Pass Data Between BLL And UI In 3-layer (single Tier) Application?

Dec 4, 2009

I am a fairly rookie programmer who is trying to learn the basics of n-layered architecture (DAL, BLL, UI). The application I am programming is a single tier, 3-layer application written in VB.NET (.Net 3.5). Layers as follows:

DAL
BLL
UI
COMMON - contains DTO's right now.

I am having trouble determining what to pass between my BLL and UI. My instinct tells me that I should only pass data to the UI, and not the full business object from the BLL. Consider two scenarios:

1) Pass the BO directly from BLL to UI. This exposes BO methods and allows the UI direct access to the BO, which seems bad.

2) Pass only the pertinent data from the BO to the UI. For instance, a customer has a Name and Address. This data is really what we want to show/edit in the UI, so we would only return that data to the UI instead of the full BO. The UI would then call to the BLL to update a specific BO.

I am inclined to use #2, but I don't know the best way to implement it. The way I have it programmed now, if I only return data from the BLL, all references to my BO's will be lost and the GC will claim them. Based on this, I have some questions:

1) Should I keep business objects alive between calls to the BLL? The alternative is to re-create them every time I pass data through the BLL, which seems wrong.

2) What is the best way to keep a BO alive in a single tier architecture (how to hold a reference if we dont pass it to the UI?)

3) How do n-tier applications do this? Do they keep the BO's alive in the BLL and wait for an update from the UI? Doesn't this require a lot of "book keeping" in the BLL to make sure BO's are released when they are no longer needed?

View 2 Replies

Walkthrough: Adding A Local Database Cache To An N-Tier Application?

Nov 5, 2009

I have followed this walkthough at http:[url]...but I am having problems working out how to save changes to the Local Database Cache so that I can use the bidirectional sync. This walkthough does not provide the code to save local changes,I have added the line of code for the bidirectional sync and it works if you drag datasources direct onto the form from the XSD but this uses the component TableAdapterManager and the method UpdateALL which I cannot see how to implement in this Walkthough ?how I change the local Database Cache and update back to server in this walkthrough ?

View 6 Replies

Using Abstract Factory Pattern In Module Console Application

Mar 1, 2011

[code]I want to write a simple text based rpg game very simple that uses the abstract factory pattern. It will be a choose your own adventure style read and options like 1.run 2.fight 3.bribe your way out of it 4.talk your way out of it, really simple. Would i create a thing pattern, then have factorys like creatures, items etc.

View 5 Replies

Show My Suggestion Box In Program?

Apr 10, 2010

Accidentally my code suggestion box [ the box when we start typing it shows us code suggestions ] is closed and i don't know how.

View 1 Replies

Auto-suggestion Text Box Custom Control?

Nov 30, 2011

I want to create an custom control just like an Autosuggest control for my windows application. When I type, it should show a grid for the suggestion have the typed value.for an example if I want to search a student "ashish". As soon as I type A in textbox, it should show its First Name, Last name, Address, its image and some other info into a grid or grid like format beneath that control. All those info will come from Database.

View 1 Replies

Multiple Words Spelling Suggestion Model?

Mar 3, 2011

I can't seem to figure out how to efficiently solve a problem.I have the following data represented like this:

Public Class WordWithSuggestions
Private _Originalword As String
Private _SpellingSuggestions As List(Of String)

[code].....

View 2 Replies

VS 2008 - Fuzzy Search With Suggestion If No Match Found

Jun 26, 2009

I'm creating a search application that needs to have a fuzzy search. Basically if there are 0 results, I need to provide a suggestion, much like google. For example, if I type "Californea", I need my program to suggest "California" after doing a query on my DB for similarity.

View 12 Replies

Can Get TextBox1's Auto-complete Suggestion To Come From TextBox2's Current Text

Dec 10, 2011

I've got a basic email application set up, and I'd like the "To" field (TextBox1) to be an autocomplete textbox.I'd also like the user to be able to edit what their contacts are, and so be able to add named to the autocomplete suggestions.I can get TextBox1's autocomplete suggestion to come from TextBox2's current Text - however this means I can only have one name as a suggested contact.Ideally, something like a list box would be ideal, so the user can add and remove names, and this list would then provide the source for the autocomplete.

View 14 Replies

N- Tier Architure In .net?

Dec 7, 2011

I want to understand N-tier architecture and example of application for same.

View 5 Replies

3 Tier And Related Tables

Dec 14, 2010

I downloaded a 3 tier sample code , but that has no code for related tables, I am trying to complete this.

These are the tables and part of the sample code

[CODE...]

View 2 Replies

N Tier Development For Win Forms?

Apr 27, 2010

I usually create N Tier applications with ASP .Net applications as per the advice at ASP .Net (data tutorials). Recently ive tried to create an N Tier Windows Form database application and found the method im use to (i.e. ASP .Net) doesnt really work (unless i was doing something wrong).

View 7 Replies

VS 2008 Creating An N-Tier?

May 20, 2009

I'm creating an N-Tier (or at least I think its N-Tier!) solution where I have the following:

WPF client side application (presentation layer)
WCF service hosted in a windows service (data access layer)
SQL database (data layer)

Now bearing in mind this is the first time I've tried to design anything like this, I might be going about it completely the wrong way...I've created 3 examples classes that would be my 'business objects' (im not quite sure where that fits in within the layers I listed above, because these business objects would be defined in a DLL that would be used by both the presentation layer and the data access layer). You can see them here:So then in my WCF service (data access layer) I would have methods like this that would be exposed to the WPF client:These are just examples but you get the idea. Is this the right way to do something like this?I saw one design that someone had posted somewhere that basically looked to me like it merged the Business Objects and the DAL together because in their class that represented an order, they had properties like you would expect for Order Number etc etc but then they also had methods like "GetOrders" within there too.I dunno I'm still very new to this type of design but I thought that the idea of the business objects was that they just represented business items, such as orders etc, so I thought they would just purely hold properties/fields and no methods or anything like that

View 20 Replies

Add Records Using N-tier And Stored Procedure?

Sep 7, 2010

how can i add records using n-tier and stored procedure""

View 1 Replies

Asp.net - Use Abstract Classes In A 3-tier Solution?

Feb 1, 2012

My immediate issue is that currently I have a 3 tier solution (Presentation.aspx.vb calls BusinessLayer.vb which calls DataAccessLayer.vb). However, I want to make BusinessLayer and DataAccessLayer.vb abstract classes because several Webforms will use have the same functionality.

So I currently am doing this (no abstract classes):

'Presentation Layer (pseudocode)
public sub checkUser(byval userName as string, byval dept as string)
dim isGood as boolean = BL.checkUserAccess(userName, dept)

[Code].....

View 1 Replies

C# - Which Options Are Ther To Set Up Your 3-Tier System

Jul 29, 2010

Which options are there to make your 3-Tier System.Client / Common / Server Now we work with the entityframework and agatha. But are there other options to make a good 3-Tier system?

The agatha framework, makes for us the request/response on the common site. On the server site the response will be filled in. But are there other framework to do all that work for you? Or should you do it without such framework. And call at the server site stored procedure? Or with LINQ? With the agatha we query the repository's with some LINQ queries.

But i am wonna know if there are other ways to do the communication. Maybe there are other and better ways to do it. I hope i get some usefull answer. Where i can read some new things.

View 2 Replies

Entity Framework, 3-tier Architecture?

May 23, 2011

I have a large application that has always existed all in a single .NET project up until recently (200,000+ LOC). I'm finally getting to the point where I can fix this. I just started using the Entity Framework (4.1 using code first) and I believe this is a good time to start seperating my logic.

What I did is I separated my application into three subprojects:UI - Windows forms project Business - The POCO classes Data - Legacy data access code AND the DBContext class to connect my POCO classes to the database. I also have a Windows service project and will soon have a WCF project, but those concern me less.

The problem is that in this plan, the data layer depends on the business layer and vice versa causing a circular reference error. There is no way around this.So, my idea is to move my POCO classes into the data layer removing all business logic first (just keeping the database fields, basically). Then, I will inherit from those classes in the business layer adding back all the business rules. Then my data access layer will not rely on any other project, the business layer will rely just on the data access layer, and the interface layer will rely on both for now but eventually only on the business layer.

Does anyone see any problems with this, or a better way of doing things given my current circumstances?

View 5 Replies

Link For N Tier Development Sample ?

May 20, 2010

I am trying to develop in my pc this basic 3 tier solution out of these links [URL] and [URL]

I have problems because the dataset in one part is OrdersDataSet.xsd, as said in the link ,but some lines bellow in the code show me this lines:

Imports ta = NorthwindDataSetTableAdapters
Partial Public Class NorthwindDataSet

Private taOrders As New ta.OrdersTableAdapter

[CODE].........

When i put this in the code it tells me an error message simmilar to this the namespace does not exist or do not have a public member.

View 4 Replies

Populate RadioButtonList Using 3-tier Logic?

Oct 21, 2010

The below code doesn't work becuase I need to somehow feed the DataText and Value fields. I need to somehow amend the code to allow me to populate my RadioButtonList and to fit inside my 3-tier architecture. My first time doing this so I'm a little lost.

' rblAnswers.DataTextField = dt.Columns(1).ToString
' rblAnswers.DataValueField = dt.Columns(0).ToString
'Calls

[code]....

View 2 Replies

VS 2010 Creating N-tier Applications?

Feb 19, 2011

I'm trying to learn this and had gone through some tutorials (found on googling).But most of them are a bit harder to understand. An easy to understand version was not found Do you know any links to a good tutorial ?

Also, where can I get a good example program written using 3-tier architecture in VB ?

View 10 Replies

What Dataclasses Should Create In A 3-tier Project

Aug 13, 2010

I have a relatively small project and I'm using a 3 tier architecture. Now I'm thinking about on how to split up some of the functions in different data classes.

For example I have a User class and a Group class. My User class has a User.GetGroups function and my Group class has a Group.GetUsers function. Would I put the first in the UserData class as UserData.GetGroups or in GroupData.GetGroupsForUser or perhaps a completely separate UserGoupData class?

View 1 Replies

3-tier Coding In Retrieving Data To Label?

Jun 21, 2010

tier coding in retrieving data from database and display it in label.

I got the code for data access layer but im not sure if it's right:
Public Function getFeedbackQ(ByVal Question1 As String, ByVal Question2 As String, ByVal Question3 As String) As System.Data.DataSet

[code].....

View 1 Replies

Populate A ComboBox Using An Array In A 3 Tier Structure

Dec 8, 2010

It's a simple 3-Tier Structure Windows Form Application using Visual Basics 2008 express edition. I need to populate a ComboBox (User Interface Layer) using an Array with only 3 names (Data Access Layer and Business Logic Layer). I think I'm close to it but I'm unable to pass the data from the DAL all the way to the UI properly. When I run the application, My ComboBox gives me choices but the three choices are

[Code]....

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved