Fog Creek Software
Discussion Board

Welcome! and rules

Joel on Software

Helpless in Norcal..."Cannot Load Type" Asp.Net

Platform:  Windows 2003
.Net Version 1.1
Visual Studio 2003

Inexplicably, all of a sudden, I am not able to run any of my web apps on my dev machine.  I get the same error for all of them:

Parser Error Message: Could not load type 'Foo.Global'.

Source Error:

Line 1:  <%@ Application Codebehind="Global.asax.vb" Inherits="Foo.Global" %>

Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

It never gets past the global.asax page.....  I tried new projects, wizard projects, sample projs, everything...same problem.  I'm theorizing that possibly one of Microsoft's automagical security updates wrecked my IIS settings.  I tried adjusting the .Net security settings with no success.  I tried the permissions in IIS...  I think I've tried everything.  I also ran the aspnet_regiis tool.    In the midst of my "problem-solving" I got a nice little message from Visual Studio that "IIS is in lockdown mode".  What the heck?

For the love of all things holy...prior to today I actually thought I knew what I was doing.

Any help is appreciated.



Steve Walker
Friday, January 9, 2004

Global.asax.vb contains a definition for Foo.Global, and you're compiling the project, correct? When you peek into the assembly in the /bin directory, does it contain a definition for Foo.Global?

Brad Wilson (
Saturday, January 10, 2004

...and does the ASPNET account have read/execute access on the /bin directory?

Duncan Smart
Sunday, January 11, 2004

Yep, I checked the bin first...recompiled it...  same response.  And I get this error for every single web app on my box, including ones that worked fine before.

Thanks for your posting.


Steve Walker
Monday, January 12, 2004

I ran into this a few times during the beta... the only thing that seemed to work for me was reinstalling the framework, and then reinitializing it within IIS.  In other words, after the framework reinstall, running "aspnet_regiis -u" and then "aspnet_regiis -i" from the framework directory.

Hope this helps.

Greg Hurlman
Monday, January 19, 2004

I found that Visual Studio.NET sometimes does a dirty trick and excludes a file from your project without you noticing.  Right-click on the file in Solution Explorer and select "Include in Project" and then rebuild...

Dan Wuensch
Tuesday, May 11, 2004

*  Recent Topics

*  Fog Creek Home