Hi,
I am getting the following error while using readymade DAL component:
Please help me to solve this error.
Please refer the attached file to get the files i used (aspx, aspx.vb, web.cofig)
An error occurred creating the configuration section handler for dataConfiguration: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Data, Version=3.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) (D:\ASPNETStudy\web.config line 12)
Actual code is:
Imports System
Imports Microsoft.Practices.EnterpriseLibrary.Data
Imports Microsoft.Practices.EnterpriseLibrary.Data.Sql
Partial Class UsingDALcomponent
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim objdb As Database = DatabaseFactory.CreateDatabase()
GridView1.DataSource = objdb.ExecuteDataSet("SPselectmem")
GridView1.DataBind()
End Sub
End Class
ASPX Page:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="UsingDALcomponent.aspx.vb" Inherits="UsingDALcomponent" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<b>Using DAL Component:<br />
<asp:GridView ID="GridView1" runat="server">
</asp:GridView>
</b>
</div>
</form>
</body>
</html>
PLEASE REF. ATTACHED ZIP FILE TO SEE THE ASPX, ASPX.VB, WEB.COFIG FILES