By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,846 Members | 1,211 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,846 IT Pros & Developers. It's quick & easy.

Could not load type 'psyche.admin.justdoit'.

P: n/a
Hi group,

I am getting the "could not load type" error and I'm not sure how to debug.
Obviously it's a namespace error but I don't see it. Below are code
snippets. Yes, the files sit in a subdirectory called "admin". The webpages
in the root directory, "psyche" do not have any errors. So it's something
with the name admin? But what? Yes, all of the webpages in the admin
directory have the same error with their respective webpages in the class
name.

The webpage admin/default.aspx shows this error
Parser Error Message: Could not load type 'psyche.admin.justdoit'.

The code behind (admin/default.aspx.cs) has the following namespace
namespace psyche.admin
{
/// <summary>
/// Summary description for _default.
/// </summary>
public class justdoit : System.Web.UI.Page
{
private void Page_Load(object sender, System.EventArgs e)
{
// Put user code to initialize the page here
}

Thanks for your help!

Andy
Nov 19 '05 #1
Share this Question
Share on Google+
9 Replies


P: n/a
Hi Andy,

The first thing I would do is make sure the compiled DLL in the BIN folder
does have that namespace and class in it.

A nice tool for investigating a .NET DLL is Reflector:

http://www.aisto.com/roeder/dotnet/

Ken
"Andy Sutorius" <an**@sutorius.com> wrote in message
news:fa*******************@twister.southeast.rr.co m...
Hi group,

I am getting the "could not load type" error and I'm not sure how to
debug.
Obviously it's a namespace error but I don't see it. Below are code
snippets. Yes, the files sit in a subdirectory called "admin". The
webpages
in the root directory, "psyche" do not have any errors. So it's something
with the name admin? But what? Yes, all of the webpages in the admin
directory have the same error with their respective webpages in the class
name.

The webpage admin/default.aspx shows this error
Parser Error Message: Could not load type 'psyche.admin.justdoit'.

The code behind (admin/default.aspx.cs) has the following namespace
namespace psyche.admin
{
/// <summary>
/// Summary description for _default.
/// </summary>
public class justdoit : System.Web.UI.Page
{
private void Page_Load(object sender, System.EventArgs e)
{
// Put user code to initialize the page here
}

Thanks for your help!

Andy


Nov 19 '05 #2

P: n/a
Ken,

Here is the result from reflector:

public class justdoit : Page
Name:psyche.admin.justdoit
Assembly:psyche, Version=1.0.1868.26508

What would be the next step?

Andy

"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:ug*************@TK2MSFTNGP09.phx.gbl...
Hi Andy,

The first thing I would do is make sure the compiled DLL in the BIN folder
does have that namespace and class in it.

A nice tool for investigating a .NET DLL is Reflector:

http://www.aisto.com/roeder/dotnet/

Ken
"Andy Sutorius" <an**@sutorius.com> wrote in message
news:fa*******************@twister.southeast.rr.co m...
Hi group,

I am getting the "could not load type" error and I'm not sure how to
debug.
Obviously it's a namespace error but I don't see it. Below are code
snippets. Yes, the files sit in a subdirectory called "admin". The
webpages
in the root directory, "psyche" do not have any errors. So it's something with the name admin? But what? Yes, all of the webpages in the admin
directory have the same error with their respective webpages in the class name.

The webpage admin/default.aspx shows this error
Parser Error Message: Could not load type 'psyche.admin.justdoit'.

The code behind (admin/default.aspx.cs) has the following namespace
namespace psyche.admin
{
/// <summary>
/// Summary description for _default.
/// </summary>
public class justdoit : System.Web.UI.Page
{
private void Page_Load(object sender, System.EventArgs e)
{
// Put user code to initialize the page here
}

Thanks for your help!

Andy

Nov 19 '05 #3

P: n/a
I take it there's no version/strong name issue and the file is in the /bin
directory?

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:%3*******************@twister.southeast.rr.co m...
Ken,

Here is the result from reflector:

public class justdoit : Page
Name:psyche.admin.justdoit
Assembly:psyche, Version=1.0.1868.26508

What would be the next step?

Andy


Nov 19 '05 #4

P: n/a
You are correct.

In trying to figure this out I created another web project inside of the
same solution. When I created the admin folder and then created a
webform1.aspx and typed in hello the webpage displayed correctly. When I
created webform2.aspx and typed in hello the webpage had a "could not load
type" error similar to the 'psyche.admin.justdoit'. Weird!
"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
I take it there's no version/strong name issue and the file is in the /bin
directory?

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:%3*******************@twister.southeast.rr.co m...
Ken,

Here is the result from reflector:

public class justdoit : Page
Name:psyche.admin.justdoit
Assembly:psyche, Version=1.0.1868.26508

What would be the next step?

Andy

Nov 19 '05 #5

P: n/a
Expanding a bit...I created a new folder (manager) in the new project
(challenge) and created a new webpage (content.aspx)...when I go to view the
page I see
Could not load type 'challenge.manager.content'.

If I build the project (challenge) the error goes away and the page displays
properly.

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:ch*******************@twister.southeast.rr.co m...
You are correct.

In trying to figure this out I created another web project inside of the
same solution. When I created the admin folder and then created a
webform1.aspx and typed in hello the webpage displayed correctly. When I
created webform2.aspx and typed in hello the webpage had a "could not load
type" error similar to the 'psyche.admin.justdoit'. Weird!
"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
I take it there's no version/strong name issue and the file is in the /bin directory?

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:%3*******************@twister.southeast.rr.co m...
Ken,

Here is the result from reflector:

public class justdoit : Page
Name:psyche.admin.justdoit
Assembly:psyche, Version=1.0.1868.26508

What would be the next step?

Andy


Nov 19 '05 #6

P: n/a
So you're okay now or is something still messed up?

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:LD*******************@twister.southeast.rr.co m...
Expanding a bit...I created a new folder (manager) in the new project
(challenge) and created a new webpage (content.aspx)...when I go to view
the
page I see
Could not load type 'challenge.manager.content'.

If I build the project (challenge) the error goes away and the page
displays
properly.


Nov 19 '05 #7

P: n/a
Ken,

The error still occurs with psyche.admin.justdoit

I just wanted to see if I could consistenly reproduce the problem with a new
project and I couldn't

I am going to publish the psyche files to my remote server and see if I get
any errors. Thanks for your help.

Andy
"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:OR**************@TK2MSFTNGP09.phx.gbl...
So you're okay now or is something still messed up?

"Andy Sutorius" <an**@sutorius.com> wrote in message
news:LD*******************@twister.southeast.rr.co m...
Expanding a bit...I created a new folder (manager) in the new project
(challenge) and created a new webpage (content.aspx)...when I go to view
the
page I see
Could not load type 'challenge.manager.content'.

If I build the project (challenge) the error goes away and the page
displays
properly.

Nov 19 '05 #8

P: n/a
Maybe something is messed up in the config file or the project's settings?
Rather than fight it, I'd just move the code into a new project. <grin>
"Andy Sutorius" <an**@sutorius.com> wrote in message
news:RX*******************@twister.southeast.rr.co m...
Ken,

The error still occurs with psyche.admin.justdoit


Nov 19 '05 #9

P: n/a
For the group...a solution...it turns out that the .dll for the project had
become corrupted. I tried deleting the dll and pdb then building the project
again but to no avail I still received the error on select webpages. I
performed a google search on the keywords could not load type and the top
result was a kb article from MS, #306155: PRB: "Could not load type" error
message when you browse to .aspx page by using Visual C# .NET. Although this
wasn't the exact problem I was having, it was certainly related. I was able
to reproduce my problem if I did not build the project every time I added a
new webpage.

Regards,

Andy


"Ken Cox [Microsoft MVP]" <BA************@sympatico.ca> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Maybe something is messed up in the config file or the project's settings?
Rather than fight it, I'd just move the code into a new project. <grin>

Nov 19 '05 #10

This discussion thread is closed

Replies have been disabled for this discussion.