In this article I will
explain How to save GridView EmptyDataTemplate (Empty Data
Template) Data in ASP.NET
To use
a GridView control a DataSource control has to
be attached to the GridView control. The property DataSourceID
of the GridView control binds the GridView control to the DataSource control
and allows paging, sorting and database operations with the DataSource.
There are four popular DataSource controls and SqlDataSource control is one of them. We use SqlDataSource control, to attach the GridView control to the Sql Server Data base.
There are four popular DataSource controls and SqlDataSource control is one of them. We use SqlDataSource control, to attach the GridView control to the Sql Server Data base.
But you couldn’t get any
data from database you need to show Empty data row for saving first record to
Database. On that time we need to use GridView EmptyDataTemplate.
Below is the design code
for GridView EmptyDataTemplate.
Design: