.NETGURU
Could Not Load Type "<>" Error
Messages   Related Types
This message was discovered on microsoft.public.dotnet.academic.

Post a new message to this list...

Don Wash
Hi All!

I'm getting the following Error:

[QUOTE]
Description: An error occurred during the parsing of a resource required to
service this request. Please review the following specific parse error
details and modify your source file appropriately.

Parser Error Message: Could not load type 'WebChartTest.WebForm1'.
[/QUOTE]

No DLLs has been compiled yet and nothing in the \bin directory. So it is
not the versioning problem or anything like that.

And here are the source of the files...

-------------START "WebForm1.aspx"-------------

<%@ Register TagPrefix="cr" Namespace="CrystalDecisions.Web"
Assembly="CrystalDecisions.Web, Version=9.1.5000.0, Culture=neutral,
PublicKeyToken=692fbea5521e1304" %>
<%@ Page Language="vb" AutoEventWireup="false" Codebehind="WebForm1.aspx.vb"
Inherits="WebChartTest.WebForm1"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<title>WebForm1</title>
<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="vs_targetSchema"
content="http://schemas.microsoft.com/intellisense/ie5";>
</HEAD>
<body MS_POSITIONING="GridLayout">
<form id="Form1" method="post" runat="server">
<CR:CrystalReportViewer id='CrystalReportViewer1' runat='server'
style="Z-INDEX: 101; LEFT: 16px; POSITION: absolute; TOP: 56px"
Height="50px" Width="350px"></CR:CrystalReportViewer>
</form>
</body>
</HTML>

-------------END "WebForm1.aspx"-------------

-------------START "WebForm1.aspx.vb"-------------

Imports System
Imports System.Web
Imports System.Web.UI

Public Class WebForm1
Inherits System.Web.UI.Page

#Region " Web Form Designer Generated Code "

'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub
InitializeComponent()

End Sub
Protected WithEvents CrystalReportViewer1 As
CrystalDecisions.Web.CrystalReportViewer

'NOTE: The following placeholder declaration is required by the Web
Form Designer.
'Do not delete or move it.
Private designerPlaceholderDeclaration As System.Object

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub

#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
CrystalReportViewer1.ReportSource = "CrystalReport1.rpt"
End Sub

End Class

-------------END "WebForm1.aspx.vb"-------------

I've also removed the Global.asax file and ran it, the error is the same. So
the error is not in the Global.asax file.

I've also tried replacing the ( Inherits="WebChartTest.WebForm1" ) with (
Inherits="WebForm1" ) in WebForm1.aspx but the error is the same. This
project sit on http://localhost/WebChartTest/

I've installed VS.NET 2003 on my computer as well as SharpDevelop RC2.

I've completely given up on the problem :( [well not completely but almost]
but I hope at least one of you can figure the problem out!

Thanks!
Don

Reply to this message...
 
    
Martin Marinov
WHen you use code behind files .net framework expects that your application
will have a dll file in your /bind directory. So when you try to start the
application .net framework throw this exception because it can not found the
needed files

So you have to rebuild your application and check ( just to be sure ) that
your .dll file is in the /bin directory

Regards
Martin
"Don Wash" <Click here to reveal e-mail address> wrote in message
news:#Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
    
Don Wash
Hi Martin!

Thanks for the reply! I didn't know it is compusalary to complie the files
first in order to run ASPX pages with code behind?

For example, the following code runs fine without any compilation to DLL

-------------------CodeBehind.aspx---------------------

<%@ Page Inherits="CBPage" Src="CodeBehind.aspx.vb" %>

<html>
<head>
<title>In-Page Coding Style</title>
</head>
<body>

<h2 id="header" runat="server" />
<hr />

<form runat="Server">
<asp:TextBox id="nameInput" runat="server" />
<asp:Button id="submit" OnClick="submit_click" runat="server" />
</form>

<asp:Label id="postBack" runat="server" />

</body>
</html>
-------------------END CodeBehind.aspx---------------------

-------------------CodeBehind.aspx.vb---------------------

Option Strict Off

Imports System
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.HtmlControls

Public Class CBPage : Inherits Page

Public nameInput As TextBox
Public header As HtmlGENERICcONTROL
Public submit As Button
Public postBack As Label

Sub Page_Load(sender As Object, e As EventArgs)

If Page.IsPostBack = False Then

submit.Text = "Click Me"
Header.innerHtml = "In-Page Coding Style Web Form"

End If

End Sub

Sub submit_Click(sender As Object, e As EventArgs)

postBack.Text = "WOW! You Clicked Me " & nameInput.Text & "!"

End Sub

End Class

-------------------END CodeBehind.aspx.vb---------------------

Any Ideas Why?

Don

"Martin Marinov" <Click here to reveal e-mail address> wrote in message
news:e%23%Click here to reveal e-mail address...
> WHen you use code behind files .net framework expects that your
application
[Original message clipped]

Reply to this message...
 
    
Martin Marinov
Unfortunatelly after copy and paste your code i couldn't start the page,
without a compilation

Martin

"Don Wash" <Click here to reveal e-mail address> wrote in message
news:#Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
    
Don Wash
Anybody else out there know how to solve this problem???

Don

"Don Wash" <Click here to reveal e-mail address> wrote in message
news:%Click here to reveal e-mail address...
[Original message clipped]

Reply to this message...
 
 
System.EventArgs
System.Object
System.Runtime.Remoting.Messaging.Header
System.Security.Cryptography.RC2
System.Web.UI.MobileControls.TextBox
System.Web.UI.Page
System.Web.UI.WebControls.TextBox
System.Windows.Forms.TextBox




ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
Ad


Need Dot Net Interview Questions?
Ask ExamGuru, Inc. for advice and help on Passing .Net Interviews
.Net Projects
Best-of-breed application framework for .NET projects, developed by ExamGuru, Inc. and ExamGuru IT
Free .net Help
Commission ExamGuru, Inc. and his team for your next bespoke software project
FogBUGZ
The only bug tracking system carefully crafted with one goal in mind: helping teams create great software.
Awesome Tools
If you don't know about these, you're missing out... IT Certification Questions
IT Interview Questions
Free Oracle 10g Training
MCSE Boortcamp
Cisco Study Guides
Cheap Study Guides
Exact Questions
Dot Net Interview Questions
Oracle OCP
Cheap Travel
Designer Perfumes - Wholesale Prices
Free Programming Tutorials
 
ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
 Copyright © ExamGuru, Inc. 2001-2006
Contact Us - Terms of Use - Privacy Policy - www.dot-net-guru.com - www.examguru.net - www.oraclesource.net - www.itinterviews.net - www.examguru.net/ITCertification