How To Implement Existing Business Layer To A SilverLight 4.0 Application

Sep 20, 2010

Lets assume that I have my own business layer containing my business objects and my business services. And I have decided to create a "SilverLight Business Application" (with SL v 4.0) and I want to use my already used Business Layer from the SL application I plan to develop.

I know that I cannot include a project which is not a SL project.

View 2 Replies


Similar Messages:

C# - Using Entity Framework With Existing Business Layer And Database?

Feb 2, 2011

I have an ASP.NET application with existing business classes and a database schema. (which I would like to keep) Currently I am using ADO.NET for the DAL, but I would like to switch to some advanced technology there for easier data retrieval.

Is EF applicable to my situation? Can I use it without splitting up my business classes and auto code generation? Can LINQ to SQL solve my problem better?

All I want to do is map my existing classes to the existing tables and dont have to handle details of the data retrieval myself.

View 1 Replies

Implement Transaction In Business Logic Layer?

Jan 17, 2011

I'am using enterprise library data access block in my asp.net application. I want to implement transaction from the Business logic layer, across multiple stored procs. Entlib opens a new connection for database access. Does using Transaction Scope in the following way lead to distributed transaction?

using (TransactionScope scope = new TransactionScope(TransactionScopeOption.Required))
{
// calling necessary DAL methods
scope.Complete();
}

Is there better methods to implement transaction from BLL?

View 1 Replies

Forms Data Controls :: How To Implement Datagrid Events In Business Layer

Jan 28, 2010

<p>Dear All </p> <p>i am developing a small asp.net application in vs 2005. my application consists of 3 layers.presentation, business layer and data layer. now i got a small problem in using datagrid events like itemcommand , databound events in presentation layer. </p><p>this is my first asp.net application with different layers , upto now i dint work with layers. i created datagrid as follows in my page load i craeted an instance for my businesslayer as </p><p>

mywebsite businesslayer .customerinfo cs = new mywebsite businesslayer .customerinfo();
</p><p>

in customer info i have a function to bind the grid

</p><p>bindgrid(datagrid dg1, datatable dt)
{
dg1.datasource=dt; dg1.databind();
}
</p><p>

now i want to add itemcommand event ad databound events. can any one advice me how to add these events and where should i have to add these events? </p><p>

<p>p
</p><p>
</p><p>kishore</p>

View 1 Replies

Architecture :: How To Pass The Values From Presentation Layer To Business Logic Layer

Oct 26, 2010

I am new to this .NET what is the difference between N-Tier and 3- Tier Architecture. If they are same. How to pass the values from presentation layer to business logic layer.

For Example

I have 10 controls in presentation layer. I passing values to these controls. How the architecture works.

View 3 Replies

Architecture :: Data Access Layer And Business Logic Layer?

Jun 24, 2010

I am building a web site following the tutorials on asp.net. I am using dataset as data access lay, and writing classes to access the dataset. But the example is just basic ideas, how do I retrieve individual table column value in the business layer?For example, if I have a table called Product, I only want to find out what is the product name by product id. I did this in my ProductBLL:

public ProductBLL
{
public int GetProductName(string productId)
{
ProductDataSet.ProductDataTable prodData = Adapter.GetProductById(productId);
[code]...

Is there a better way, or am I doing this correctly? Can anybody give me a reference to a more complicated business logic model?

View 16 Replies

C# - Using Silverlight With Existing Application?

May 5, 2010

This seems like a very basic question but I couldn't find any help on web. If you could provide some link or steps to do this.I have created few basic Silverlight applications which are working fine standalone. I also have a basic ASP.NET application with a solution with around 10 Class Library Projects and 1 website. I want to create a small popup which will have some funtionality using Silverlight.How should I go about creating this application and how to integrate it with my existing application for it to show as a link. I would not want that link to open another application/site.

View 2 Replies

MVC :: How To Make Business Layer Seperate From Presentation Layer

Feb 23, 2011

I've even got my JQuery Ajax submission going on now but I've encountered another problem. I *think* it's something to do with the structure I'm using but like I say, I'm fairly newo this.I have my AJAX form submission which builds my "PersonViewModel" (model for the presentation layer) in JSON and sends it to "@Url.Action("RegisterSubmit")" in my Person Controller. Now, I seperate my business layer from my View/presentation layer so in "RegisterSubmit"I'm verifying the model is valid then instantiating a new instance of my business model "Person", adding the values from "PersonViewModel" and then calling my "Save" function.

View 7 Replies

Business Layer Errors And Service Layer Handling?

Mar 7, 2011

We're building a large web app that has numerous layers. In order to communicate to the business layer we're using a service layer that the web layer calls when data is needed. Unfortunately, it seems that if exceptions are thrown in the business layer, it seems that the services on the web side are wrapping the exceptions and re-throwing them. We're looking for a clear way to encapsulate the error and log it, without WCF wrapping a new exception around the original.

View 2 Replies

C# - N-layer Business/service Layer Design?

Jan 26, 2011

I'm trying to reevaluate our n-layer architecture and would love to get some based on your experiences. Here is our typical .NET n-layer (sometimes n-tier) design.

Project.UI
Project.Services
Project.Business
Project.Model
Project.DataAccess

DataAccess typically consists of Entity Framework 4 and Repository classes. I attempt to follow the Aggregate Root concept in order to avoid having a repository for table, easier said than done in my experience. I tend to have ~70% match between Repositories and Tables.

Model usually consists of my Entity Framework 4 entities, I've been using Self-Tracking EF entities with success.

Business is what I struggle with the most. I typically have a Manager class for every Repository. This class will contain methods like .Add() which will perform business validation before forwarding down to repository.Add().

Services, typically I will only implement this if in fact I am looking to create a web service based solution. This layer will be tasked with marshaling requests/responses between DTOs and entities. And most importantly provide the more coarse grained interface. For example a TradingService.SubmitTrade(), which is really a facade for a business transaction which might include AccountManager.ValidateCash(), OrderManager.SubmitOrder(), etc.

My business layer is very entity centric, really it's just the glue between the entities and the repository, with validation in between. I've seen many designs where the Service Layer is what holds a reference to the repositories (in essence skipping the "business layer"). In essence it serves the same purpose as my Business layer, it does the validation, however its' responsibility (and naming) is a higher level, more coarse grained business transaction. Using the example above the TradingService.submitTrade() will not delegate to any business manager classes, it would itself query the necessary repositories, perform all the validation etc.

I like my design in a sense that I can reuse a business layer method in multiple service calls, however I hate the fact that for every repository I have a matching business layer manager, creating tons of extra work. Maybe the solution is a different type of grouping at the Business Layer level? For example combine individual Manager classes like PhoneManager and EmailManager (note I have Phone entities and Email entities) into a logical Manager class such as ContactsManager (note I don't have a "Contact" entity type). With methods such as ContactManager.GetPhones() and ContactManager.GetEmail(), etc.

View 1 Replies

C# - How To Implement And Maintain E-commerce Application When Business Don't Want To Disclose Merchant Details To Developers

Jan 14, 2010

Recently we've developed an E-Commerce web application for a client. We are at the stage before launch and the client is not happy to disclosing live merchant account details to us because they don't want us to potentially being able to see their clients' data.

Since we are going to maintain their website (running off their servers but we will still have access to the site files) I cannot see an easy solution to this other than trust.

How to implement and maintain E-commerce application when business don't want to disclose merchant details to developers?

View 2 Replies

Architecture :: How To Pass The Data Between Data Access Layer And Business Acces Layer

Jun 3, 2010

here i have in 3-tier architecture , how to pass the data between DAL and BAL. i am using grid view to edit the data,when ever i click on the edit button all the corresponding fields should come to textboxes. i tried for delete ,it works fine bt not working to EDIT.

View 7 Replies

AJAX :: Implement Within An Existing Application / Slow Response?

Jan 31, 2011

I'm trying to implement AJAX within an existing application and it seems to be running slow.

I have 3 datallist that all have checkboxs. I have buttons that all users to check all checkbox for a specific datalist. I have an update panel around each datalist. When I check and uncheck it seems to be really slow. I also have 3 textboxes and 4
buttons within my update panel.

When I user uses this site it hides and shows different panels and that seems to be really slow when the users press a button. There is no database stuff happening when the slowness occurs.

View 2 Replies

Using LINQ In Business Layer?

Sep 28, 2010

I'm wondering how can I use LINQ in here?

Code:
public Northwind.ProductsDataTable GetProducts()
{
[Can I use Linq here?]
return Adapter.GetProducts();
}
I followed the way of using Business Layer through this tutorial and I'm wondering how I can use LINQ there:

View 1 Replies

How To Use Of Business Layer In 3-tier Architecture

Jan 27, 2011

I am implementing 3-tier architecture. I just wanted to know the role of business layer in 3-tier architecture.

I am developing application in using entity framework. So I have entity object which is accessiable in PL,BL & DL. My question is whether input assignment to entity object should be in PL OR BL.(Consider there is save method)

View 2 Replies

Best Practice For Authorization In The Business Layer?

Sep 9, 2010

What is the best way (for a .Net 4 project) to implement authorization in the business layer. Simply I want to check whether a certain identity can access a certain action/resource.

I've tried to look this up in Patterns & Practices, but haven't found anything useful yet.

And what about PrincipalPermission of ASP.Net 2.0? Is this still relevant? What about maintenance?

I want to use an elegant solution, preferably (re)using asp.net role management.

View 2 Replies

ADO.NET :: Getting Error When Connecting To Business Layer

Mar 7, 2011

I have a application with a 3-tier architecture. Onclick event of a button, I am calling a method in my code behind file. This method is defined in the Interface( Interface resides in my Business layer) and the implemtation of this method is given in the Data access layer.

The business layer and DAL are on different projects. I have compiled the entire solution and it complies OK. Now when I try to click the button I get the error:

"The method 'doInsertCust' was not found on the interface/type 'My.Type, MyTypeLibrary, Version=1.0.2371.15203, Culture=neutral, PublicKeyToken=null'.".

Note that I have already build the Business layer and DAL and the respective DLL gets automatically refreshed.

View 4 Replies

ADO.NET :: DataTable Getting Null In Business Layer?

Aug 6, 2010

My application has a three tier architectute

UI Business DataAccess Here, I'm calling a SP from Data Access layer which will populate a DataTable and return the DataTable back to Business. My source code is like below.

[Code]....

Here, when I set debugpoint I can see the DataTable is getting populated by the data so my

sp idreturning the data. there is no issue with the sp and dataaccess layer method. The problem lies below on my business layer. The source code is like below.

[Code]....

View 2 Replies

Getting Error When Connecting To Business Layer?

Mar 7, 2011

I have a application with a 3-tier architecture. Onclick event of a button, I am calling a method in my code behind file. This method is defined in the Interface( Interface resides in my Business layer) and the implemtation of this method is given in the Data access layer.

The business layer and DAL are on different projects. I have compiled the entire solution and it complies OK. Now when I try to click the button I get the error:

"The method 'doInsertCust' was not found on the interface/type 'My.Type, MyTypeLibrary, Version=1.0.2371.15203, Culture=neutral, PublicKeyToken=null'.".

Note that I have already build the Business layer and DAL and the respective DLL gets automatically refreshed.

View 10 Replies

Architecture :: Set Images In Business Layer?

Dec 17, 2010

I am creating an ASP.NET MVC application and want to display an icon in the view based on a value of a property in the model. I guess I want to have the logic deciding which image to show in the business layer (which is in a separate class library project) but the actual images files in the web application's "Content" folder. Should I set the url of the image in the business layer? I don't want the business layer to know that is serves a web application, it can be a Windows Form or WPF application as well. If I set the url with System.Web.HttpContext.Current.Server.MapPath it feels like I am getting an unwanted dependency on System.Web, right? What are the options here?

View 1 Replies

Business Layer And Datasets / TableAdapter

Apr 3, 2012

I have a website and it was running great but wanted to move my business logic/datasets over to its own project.

That seems to be working well, I can access my functions etc from my bl dll. But I cant access my tableadapters like i used to be able to directly.

Do I have to make classes that access all those tableadapters or am I missing some reference I need to add?

I seem to be able to get the dataset for example mydataset But the intellisense doesnt pull up mydatasettableadapter

View 1 Replies

Architecture :: Passing Entities To Business Layer?

Mar 30, 2011

I am working on implementing a web application in ASP.Net by following the MVC design pattern (Not ASP.Net MVC). As part of the design, we have entity objects that has only properties as per the corresponding table structure and the idea is using these entity objects in the view layer and the same entity objects are passed to Persistence Layer for saving the data to the database. Business Objects in the business layer are responsible for interacting with the database.

As view creates the entity objects and passes to next layer, what would be the best practice to pass the entity objects to the business layer? Should the business objects accept data objects as parameters and interact with the persistence layer? Is there any other best practice to pass the required objects from the view layer to the next layer? As business objects also need to access the properties of the entity objects passed from the view layer, do we need any "translation" from entity objects to business objects?

the best practices to pass entity objects from view layer to the next layer and also how the entity objects created by the persistence layer can be used by business objects?

View 6 Replies

VS 2010 - Business Layer Constraint Error

Feb 22, 2012

I'm working on an application using a 3 tier architecture and I'm having issues with a business layer select method. Basically, I have a gridview control that is populated by an objectDataSource. The ObjectDataSource calls a select method in the my business logic layer to retrieve data. When the business logic layer calls a table adapter method, I receive the following error message:

Failed to enable constraints. One or more rows contain values violating non-null, unique, or foreign-key constraints

This is my first attempt at a 3 tier design and I'm not sure where to start with the debugging process.

Also, the stored procedure that is used by the table adapter select method, creates a new column inside of the query. This column is not included in the datasets datatable. I manually inserted a new column into the datatable from the dataset designer. The new column was created to store the values that are being returned from the new column in the stored procedure. I'm not sure if this is the correct way to do this or not but it allowed me to access the column in the business logic layer methods.

View 1 Replies

Attaching Linq To Sql Datacontext To Httpcontext In Business Layer

Mar 20, 2010

I need my linq to sql datacontext to be available across my business/data layer for all my repository objects to access. However since this is a web app, I want to create and destroy it per request. I'm wondering if having a singleton class that can lazily create and attach the datacontext to current HttpContext would work. My question is: would the datacontext get disposed automatically when the request ends? Below is the code for what I'm thinking. Would this accomplish my purpose: have a thread-safe datacontext instance that is lazily available and is automatically disposed when the request ends?

public class SingletonDC
{
public static NorthwindDataContext Default
{
get
{
NorthwindDataContext defaultInstance = (NorthwindDataContext)System.Web.HttpContext.Current.Items["datacontext"];
if (defaultInstance == null)
{
defaultInstance = new NorthwindDataContext();
System.Web.HttpContext.Current.Items.Add("datacontext", defaultInstance);
}
return defaultInstance;
}
}
}

View 1 Replies

Classic ASP App Has COM 'middle Layer' For Light Business Logic?

Oct 19, 2010

I am trying to estimate how long it will take to migrate a Classic ASP application to .NET and came across hundreds of COM functions written in VB 6.

A majority of these functions only do parameter validation and actually calls the SQL server. Is this something that should be replace with an ORM? (Linq, nHibernate, Entity Framework)... or should there be more to this picture?

View 1 Replies







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