Parameter and ParameterCollection in ADO.NET

In this article, I will discuss Parameter and ParameterCollection in ADO.NET. Basically, ADO.NET supports both parameterized as well as non-parameterized queries. While non-parameterized query follows the following syntax, In this case, we use a literal directly in the query. However, a parameterized query uses the parameter name in place of the literal. In fact, a …

Database Manipulation Using DataGrid

This article describes Database Manipulation Using DataGrid in ASP.NET. Basically, DtaGrid is a data-bound control in ASP.NET. In order to perform database manipulation operations, the DataGrid control is quite useful as it provides all the necessary features in a single control. In other words, DataGrid control is a feature-rich and flexible control for carrying out …

Example of Chart Control in ASP.NET

This article shows an example of Chart Control in ASP.NET. Basically, the Chart Web Control makes use of the Chart class. In fact, you can create almost any type of chart using this control. The Chart Class As I have said earlier, the Chart class is available in System.Web.DataVisualization namespace provides the functionality for the Chart control. Evidently, it has …

Creating a DataTable from a DataReader in ASP.NET

Although, there are many ways to create a DataTable object, in this article I will explain Creating a DataTable from a DataReader object. To begin with, first I will explain the DataReader object in brief. DataReader in ADO.NET Basically, a DataReader object in ADO.NET represents the connected approach of data access. A DataReader object provides read-only and forward-only …

Deleting a Record using DataGrid Control in ASP.NET

The following example shows Deleting a Record using DataGrid Control in ASP.NET. To begin with, first, understand what is a DataGrid control and how to use it in a Web Form. For this purpose, you can go through following articles to get an understanding of the DataGrid control. CRUD Operations with DataGrid in ASP.NET Creating Columns in a …

Edit a Record Using DataGrid Control in ASP.NET

The following example demonstrates how to Edit a Record Using DataGrid Control in ASP.NET. Before proceeding further, you can go through these examples on DataGrid control that I have posted earlier. CRUD Operations with DataGrid in ASP.NET Creating Columns in a DataGrid Control Insert a Record Using ItemCommand Event in DataGrid Meanwhile, we use a TemplateColumn as before …

Insert a Record Using ItemCommand Event in DataGrid

This article demonstrates how to Insert a Record Using ItemCommand Event in DataGrid. Before proceeding further, you can go through these articles for an understanding of the DataGrid control. CRUD Operations with DataGrid in ASP.NET Creating Columns in a DataGrid Control Since we are using the same database table Items in this example, there are four fields …

CRUD Operations with DataGrid in ASP.NET

To begin with, the CRUD operations stand for Create, Read, Update, and Delete. As can be seen, the CRUD operations are essential in most web applications that maintain data. Today I will explain how to perform CRUD Operations with DataGrid in ASP.NET. Basically, DataGrid is a data-bound control in ASP.NET. Therefore, it can display the data from a data …

Creating Columns in a DataGrid Control

The following example shows Creating Columns in a DataGrid Control. Before going through this example, get an overview of DataGrid control by reading this article. As I have noted earlier, our SQL Server database has a table called Items with fields – item_id, item_name, price, quantity. Therefore, we create four TemplateColumns, one for each field. In …