ExpertRating - Online Certification and Employment Testing ExpertRating - Online Certification and Employment Testing ExpertRating - Online Certification and Employment Testing

ExpertRating Home
ExpertRating Benefits
Recommend ExpertRating
Suggest More Tests
Privacy Policy
ASP Dot Net Tutorial - Index
ASP Dot Net Tutorial - Microsofts ASP.NET
ASP Dot Net Tutorial - Begining Web Forms
ASP Dot Net Tutorial - User Controls
ASP Dot Net Tutorial - ADO .NET
ASP Dot Net Tutorial - DataBinding to WebControls
ASP Dot Net Tutorial - DataList Controls
ASP Dot Net Tutorial - DataGrid Control
ASP Dot Net Tutorial - Advance Practical Examples on DataGrid
ASP Dot Net Tutorial - Working with DataSets
ASP Dot Net Tutorial - Working with XML
ASP Dot Net Tutorial - Forms Based Authentication
ASP Dot Net Tutorial - Windows Based Authentication

Online Personal Trainer Certification
Personal Trainer Certification (Spanish)
Six Sigma Certification
Find a Personal Trainer
Project Management Certification
Six Sigma Certification
Six Sigma Black Belt Certification
Master Black Belt Certification
Six Sigma Green Belt Certification
Life Coach Certification
Lean Management Certification
Lean Six Sigma Certification
First Aid Certification
CPR Certification
Yoga Certification
Aerobics Certification
Pilates Certification
Business Analyst Certification
SEO Certification
Online Business Writing Course & Certification
Makeup Artist Certification
Baby Sitting Course & Certification
Time Management Certification
Health Club Management Certification
Medical Coding Certification
Medical Billing Certification
Business Analysis Course
Master Trainer Certification
Total Quality Management Certification
Kaizen Certification
Creative Writing Certification
Event Management Certification
Test Search by Job Title
Administrative Assistant Certification
Virtual Assistant Certification
  All Online Courses


  Home > Courses, Tutorials & eBooks > ASP.NET Tutorial > Working with DataSets

ASP.NET Tutorial - Working with DataSets

                                                                                                                 Page 3 of 5

Binding Controls to a Dataset

A DataSet can be used with an ASP.NET page, using the Repeater, DataList, and DataGrid controls in exactly the same way as with a DataReader.

The following example, displays the contents of the Employees database table in a DataGrid control.

The output of above example is shown below:

It is seen the the DataGrid control is bound to the Products database table with the following two lines of codes:

dgrdEmployees.DataSource = dstEmployees


The first statement assigns the first table in the DataSet to the DataGrid control's DataSource property.

The second statement actually binds the data from the DataSet to the DataGrid control, populating the DataGrid with the items from the DataSet.

Understanding DataTables

The DataTable is a central object in the ADO.NET library. Other objects that use the DataTable are the DataSet and the DataView.

When DataTable objects are accessed, note that they are conditionally case-sensitive. For example, if one DataTable is named "mydatatable" and another is named "Mydatatable", a string used, to search for one of the tables is regarded as case-sensitive. However, if "mydatatable" exists and "Mydatatable" does not, the search string is regarded as case-insensitive.

A DataTable is a memory-resident representation of a database table in a DataSet.



Home  |  About Us  |  Privacy Policy  |  Site Map  |  FAQs  |  Contact Us
© ExpertRating 2015. All Rights Reserved.