Solved

how to expose existing data access class in c# as a webservice

Posted on 2013-02-03
2
230 Views
Last Modified: 2013-02-06
i have a data access class, which calls certain stored procedures and get data from the sql server database. Can I access all the methods in this class via webservice?
0
Comment
Question by:mmalik15
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 75

Accepted Solution

by:
käµfm³d   👽 earned 400 total points
ID: 38849456
Sure. It sounds like you've created yourself an n-tiered architecture. You just need to create a layer that is called from within the service and which accesses your existing code. You would probably want to wrap your existing code up as a library (DLL) and just reference it within your service project.
0
 
LVL 1

Assisted Solution

by:mgbm_it
mgbm_it earned 100 total points
ID: 38854482
the way I would do this would be to create a LINQ to SQL class, add all tables to it then create functions which will perform all required operations then create web service that contains all functions.

there is not shortcut for this... you need to get your hands dirty a little bit :)
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
c#  FTP ftpwebrequest URI invalid 6 47
SSIS Column mapping 5 42
Pdf not loading 2 40
C#line chart with data on Y and time on X-axis 3 32
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question