Introduction
Today, in this article let's play around with one of the interesting and most useful concepts in .NET 4.5.
Question: What is enhanced delete support?
In simple terms "It provides enhanced deleting support with various methods invocation as per the usage".
Step 1: Create a new "ASP.Net Web Forms Application", as in:

Step 2: Create an Entity Data Model Framework and set it up with an appropriate database.
Step 3: The complete code of webform1.aspx looks like this:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="EnhancedDeleteSupportApp.WebForm1" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<center>
<div>
<asp:GridView ID="GridView1" runat="server" BackColor="LightGoldenrodYellow" ItemType="EnhancedDeleteSupportApp.Employee"
BorderColor="Tan" BorderWidth="1px" CellPadding="2" ForeColor="Black" GridLines="None"
AutoGenerateColumns="false" SelectMethod="GetData" UpdateMethod="UpdateData"
AutoGenerateEditButton="true" AutoGenerateDeleteButton="true" DeleteMethod="DeleteData">
<AlternatingRowStyle BackColor="PaleGoldenrod"></AlternatingRowStyle>
<FooterStyle BackColor="Tan"></FooterStyle>
<HeaderStyle BackColor="Tan" Font-Bold="True"></HeaderStyle>
<PagerStyle HorizontalAlign="Center" BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue">
</PagerStyle>
<SelectedRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite"></SelectedRowStyle>
<SortedAscendingCellStyle BackColor="#FAFAE7"></SortedAscendingCellStyle>
<SortedAscendingHeaderStyle BackColor="#DAC09E"></SortedAscendingHeaderStyle>
<SortedDescendingCellStyle BackColor="#E1DB9C"></SortedDescendingCellStyle>
<SortedDescendingHeaderStyle BackColor="#C2A47B"></SortedDescendingHeaderStyle>




Join the conversation! Your thoughts help the community grow.