
Projects By LANGUAGE
Libraries
Articles & seminars
Source Code

| Building a Custom Class in ASP.NET and C# | ||||||||||
| In this tutorial, we will look at how to create a Custom Class that will represent an object. When working with databases in Web Applications, it is often useful to have an object representing that data, rather than using the built-in types such as a DataTable. By creating your own class, you can gain access to the Properties instead of referencing row and column numbers. An example would be if you're working with data from a database that consisted of a group of people. The columns could be name, age, and telephone. If you used a datatable to retrieve and interact with this data, it could get messy very quickly. But if you created a class to represent the data, then you would be able to programmatically reference the properties (name, age, and telephone) directly. | ||||||||||
|
| ||||||||||
|
||||||||||
