I have a project I'm working on in VS2005 using vb.net with a MSSql
2005 backend. Everytime I try to run the application I get the same
error message;
********* ERROR *********
Compilation Error
Description: An error occurred during the compilation of a resource
required to service this request. Please review the following specific
error details and modify your source code appropriately.
Compiler Error Message: ASPNET: Make sure that the class defined in
this code file matches the 'inherits' attribute, and that it extends
the correct base class (e.g. Page or UserControl).
Source Error:
Line 1: Imports IUSProductivity .DataSet1TableA dapters
Line 2:
Line 3: Partial Public Class AllCategories
Source File: C:\Documents and Settings\jaime. cruz.UDG\My
Documents\Visua l Studio
2005\Projects\I USProductivity\ IUSProductivity \AllCategories. aspx.vb
Line: 1
********* END ERROR *********
This is a brand new project with only one page that has a simple
DataGrid displaying data from a DataSet file with one Table Adapter.
If anyone can identify the cause of this error I would be very grateful
as I am completely at a loss as to why this is happening.
Page code is as follows;
******* ASPX FILE ******
<%@ Page Language="vb" CodeFile="AllCa tegories.aspx.v b"
Inherits="IUSPr oductivity.AllC ategories" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>All Main Categories</title>
<link href="styleShee t.css" rel="stylesheet " type="text/css" />
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:DataGrid ID="GridView1" runat="server">
<HeaderStyle CssClass="Heade rStyle" BackColor="#507 CD1"
Font-Bold="True" ForeColor="Whit e" />
<ItemStyle CssClass="RowSt yle" BackColor="#EFF 3FB" />
<AlternatingIte mStyle CssClass="Alter nateRowStyle"
BackColor="Whit e" />
<FooterStyle BackColor="#507 CD1" Font-Bold="True"
ForeColor="Whit e" />
<EditItemStyl e BackColor="#246 1BF" />
<SelectedItemSt yle BackColor="#D1D DF1" Font-Bold="True"
ForeColor="#333 333" />
<PagerStyle BackColor="#246 1BF" ForeColor="Whit e"
HorizontalAlign ="Center" />
</asp:DataGrid>
</div>
</form>
</body>
</html>
****** END ASPX FILE CODE ******
****** CODE FILE CODE *********
Imports IUSProductivity .DataSet1TableA dapters
Partial Public Class AllCategories
Inherits System.Web.UI.P age
Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArg s) Handles Me.Load
Dim MainCatAdapter As New tblMainCategory TableAdapter
GridView1.DataS ource = MainCatAdapter. GetData
GridView1.DataB ind()
End Sub
End Class
******** CODE FILE CODE END *********