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 > The DataGrid Control

ASP.NET Tutorial - The DataGrid Control

                                                                                                                 Page 3 of 4

The above example, displays only the FirstName and LastName columns from the Employees table.

Note that the DataGrid control's AutoGenerateColumns property is set to the value False so that, all the columns from the Employees table are displayed, and the FirstName and LastName columns are displayed twice as shown below: -

Therefore it is important to take care of AutoGenerateColumns property of DatGrid control.

Further in the above example the BoundColumns are declared inside the DataGrid control's <Columns> tag. This tag contains a BoundColumn for the Titles column and a BoundColumn for the Price column. The DataField property indicates the field from the data source to display in the BoundColumn.

Adding a HyperLinkColumn to DataGrid Control

This is a very important concept in DataGrid Controls. To display links to other pages from the DataGrid, a HyperLinkColumncan be used.

This type of column is useful in two situations.

First, a HyperLinkColumn can be used, for example create a master-detail form. A set of master records can be displayed in a DataGrid and a HyperLinkColumn can be used in the DataGrid to link to a separate page that contains detailed information.

Secondly it can be used for interlinking pages and websites with each other, an important need of web programmers.

For example, you can use a HyperLinkColumn to display a list of useful ASP.NET Web sites.




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