473,503 Members | 1,671 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Could not load file or assembly *

I have checked around and could not find anything here that exactly matches
my issue, which is odd since I have found numerous posts on this in other
news groups. I have a ASP .Net 2.0 site that is distributed as code (the
pages are not precompiled, but code behind is used). From time to time I get
the following error:
Could not load file or assembly 'App_Web_u2h48fgb, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system
cannot find the file specified.

The name of the assembly is different, but otherwise the error is the same.
The only work around I've found (by looking at other news groups) is to
delete the websites folder from
C:\WINDOWS\Microsoft.Net\Framework\v2.0.50727\Temp orary ASP.NET Files. Once
the folder is deleted, the web site will come up without issue.

Surely there is a better solution to this or perhaps a way to avoid this
error.
Sep 19 '06 #1
2 2585
you probably did not include page directives for references to other pages
or user controls. pages are compiled into seperate dlls, so one page can not
reference another without a page directive. but on the first compile, pages
are batched into a single dll (for compile performance), so the directive is
not required if the pages end up in the same compile batch.

-- bruce (sqlwork.com)
"John Bailey" <Jo********@discussions.microsoft.comwrote in message
news:3C**********************************@microsof t.com...
>I have checked around and could not find anything here that exactly matches
my issue, which is odd since I have found numerous posts on this in other
news groups. I have a ASP .Net 2.0 site that is distributed as code (the
pages are not precompiled, but code behind is used). From time to time I
get
the following error:
Could not load file or assembly 'App_Web_u2h48fgb, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null' or one of its dependencies. The
system
cannot find the file specified.

The name of the assembly is different, but otherwise the error is the
same.
The only work around I've found (by looking at other news groups) is to
delete the websites folder from
C:\WINDOWS\Microsoft.Net\Framework\v2.0.50727\Temp orary ASP.NET Files.
Once
the folder is deleted, the web site will come up without issue.

Surely there is a better solution to this or perhaps a way to avoid this
error.

Sep 19 '06 #2
The directives to the controls are included in the controls that reference
them.

Also, although the app code directory is compiled into a single assembly,
each control and page are actually compiled into separate assemblies. This
is true even if you are publishing the site precompiled or the first time the
site is compiled (I removed my directory from temporary internet files and
reran my site to confirm this behavior). There are some dlls that get
created that do not appear to correspond to either a page, control or the app
code directory, and sometimes one of these has the issue, but most of the
time it is a dll from one of the controls.

What makes this error even more frustrating is that the assembly that it
references in the error is present in the directory, and often it has no
dependencies other than ASP .Net controls.

The one thing this page does have is nested user controls. The page
contains a web user control (control A), and this web user control contains
another web user control (control B). The control A has the appropriate
reference to control B, but the page only has a reference to control A. I am
hoping that you are not implying that the page has to have a reference to any
controls nested in the web user controls it contains, because this would be
pretty ridiculous and would be a maintenance nightmare (just imagine if you
modified control A down the road after it had been used in a few dozen places
and added a web user control to it).

"bruce barker (sqlwork.com)" wrote:
you probably did not include page directives for references to other pages
or user controls. pages are compiled into seperate dlls, so one page can not
reference another without a page directive. but on the first compile, pages
are batched into a single dll (for compile performance), so the directive is
not required if the pages end up in the same compile batch.

-- bruce (sqlwork.com)
"John Bailey" <Jo********@discussions.microsoft.comwrote in message
news:3C**********************************@microsof t.com...
I have checked around and could not find anything here that exactly matches
my issue, which is odd since I have found numerous posts on this in other
news groups. I have a ASP .Net 2.0 site that is distributed as code (the
pages are not precompiled, but code behind is used). From time to time I
get
the following error:
Could not load file or assembly 'App_Web_u2h48fgb, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null' or one of its dependencies. The
system
cannot find the file specified.

The name of the assembly is different, but otherwise the error is the
same.
The only work around I've found (by looking at other news groups) is to
delete the websites folder from
C:\WINDOWS\Microsoft.Net\Framework\v2.0.50727\Temp orary ASP.NET Files.
Once
the folder is deleted, the web site will come up without issue.

Surely there is a better solution to this or perhaps a way to avoid this
error.


Sep 20 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
568
by: Eric Falsken | last post by:
Eric Falsken <eric@db4o.com> wrote on 04 Dec 2005: > craigkenisston@hotmail.com wrote on 19 Nov 2005: > >> I'm working in the migration of an asp.net application in 1.1 to 2.0. >> I'm new to...
1
10774
by: urs | last post by:
Two days ago, I built an ASP.NET 2.0 application and published it on a shared IIS 6 Web server. After publishing, and during the whole day, it worked fine. The server remained untouched since....
1
3549
by: ddelaney | last post by:
I've seen this posted before in many places, but have yet to find a real fix. I have a web application on dev server right now, and randomly, hours or days, it returns the expception posted below. ...
4
3968
by: Richard Bysouth | last post by:
Hi I am running a site built on asp.net 1.1 on a windows server 2003 (which is running asp.net 2.0 - shared hosting at my webhost). The site is low traffic and very simple (mostly static text...
2
151628
by: antonyliu2002 | last post by:
I am testing AJAX. I've downloaded the AJAX Extension and the CTP December package and installed on BOTH my development machine and the production server. Then I created a very very simple web...
1
18284
by: naimishranderi | last post by:
Hello friends I am using ASP.NET 2.0 and SQL Server 2000 for DB synchronization(replication) project. When I am running this web application on local machine it running fine, but when I deploy...
3
10755
by: pratikkagda | last post by:
Hi all, My system contains Framework 3.5 with visual studio 2008 as well as 2005; here I have developed an application with crystal report with framework 2.0. It is working great in my system but...
0
3927
by: Andy | last post by:
Thanks Peter, I thought I'd give an update on this problem. My application had 2 assemblies that contained classed for the Data access and business logic layer. It was on one of them that I was...
1
8296
by: Steve Wofford | last post by:
I am recieving the following. This happens when I moved it from my development system to our production SBS 2003 w/ latest .net frameworks and service packs . I developed under XPSP2 and VS2008. ...
4
4891
by: lasida | last post by:
Hi, I have developed an application in C#. Now I'm working on a tool which is again written in c# which will give me all the assemblies referenced by my application. In the code i need to get...
0
7202
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7086
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7280
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7332
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6991
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5578
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
1512
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
736
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
382
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.