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
Solved

Row returned from Database to an Entity object

Posted on 2004-09-23
4
211 Views
Last Modified: 2010-04-15
Hi All,
 In my application, i am reading a set of columns from the database. The row returned has to be converted to an C# object. I could have created a class with attributes and set the attributes when data is read. However, the columns i read vary based on a configuration file. Is there a way to convert the data returned from the Database into an object.
Thanks,
Preetham.
0
Comment
Question by:kingpreetham
4 Comments
 
LVL 10

Accepted Solution

by:
eternal_21 earned 50 total points
ID: 12135511
Not very easily.... And it won't be strongly-typed, so I can't see the advantage.  Why don't you just work with the System.Data.DataRow object?
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Introduction This article series is supposed to shed some light on the use of IDisposable and objects that inherit from it. In essence, a more apt title for this article would be: using (IDisposable) {}. I’m just not sure how many people would ge…
Summary: Persistence is the capability of an application to store the state of objects and recover it when necessary. This article compares the two common types of serialization in aspects of data access, readability, and runtime cost. A ready-to…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

808 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