473,624 Members | 2,612 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

question about Temporary ASP.NET Files folder

Roy
My dll file is copied to the
"%windir%\Micro soft.NET\Framew ork\{version}Te mporary ASP.NET Files" folder
when I compile my asp.net project. When I run the application. The dll under
this folder is loaded, not the one under bin folder. Why is that? How can I
load the one under bin folder?

Nov 18 '05 #1
5 4448
I believe, and hopefully someone will correct me if I'm wrong, the dll's in
your bin folder are those of your .cs/.vb files (codebehind, custom
classes..) as well are resource files and anything else embedded. The .dll
in the temp folder is created dynamically for the aspx files (the ones with
all the html in them). you can't change this behaviour. In 2.0, you'll
have 4 different types of compilation, one of which is what you want.

Karl

"Roy" <Ro*@discussion s.microsoft.com > wrote in message
news:32******** *************** ***********@mic rosoft.com...
My dll file is copied to the
"%windir%\Micro soft.NET\Framew ork\{version}Te mporary ASP.NET Files" folder
when I compile my asp.net project. When I run the application. The dll under this folder is loaded, not the one under bin folder. Why is that? How can I load the one under bin folder?

Nov 18 '05 #2
Hi Roy:

I believe the ASP.NET team was trying to reduce the number of
scenarios where you have to restart the web application.
If ASP.NET loaded the DLL from the bin folder, the DLL would become
locked. The only way to update the DLL would be to stop the web
application to release the lock and then copy in the new DLL.

The way it works now is ASP.NET makes a shadow copy of the DLLs in the
bin directory. If you slide in a new version ASP.NET will detect the
new file, shadow copy and load it up.

HTH,

--
Scott
http://www.OdeToCode.com

On Thu, 19 Aug 2004 06:07:02 -0700, Roy
<Ro*@discussion s.microsoft.com > wrote:
My dll file is copied to the
"%windir%\Micr osoft.NET\Frame work\{version}T emporary ASP.NET Files" folder
when I compile my asp.net project. When I run the application. The dll under
this folder is loaded, not the one under bin folder. Why is that? How can I
load the one under bin folder?


Nov 18 '05 #3
Roy
I can understand the reason you gave. But it confuses me more since it
complecates the deployment. I have a subfolder with some resource files under
it. This folder is relative to the bin folder, which means I can get the
folder dynamically from my assembly dll under bin folder. If the dll loaded
is the one under temporary folder, I cannot use XCopy to deploy my project.
How can I resolve it?

"Scott Allen" wrote:
Hi Roy:

I believe the ASP.NET team was trying to reduce the number of
scenarios where you have to restart the web application.
If ASP.NET loaded the DLL from the bin folder, the DLL would become
locked. The only way to update the DLL would be to stop the web
application to release the lock and then copy in the new DLL.

The way it works now is ASP.NET makes a shadow copy of the DLLs in the
bin directory. If you slide in a new version ASP.NET will detect the
new file, shadow copy and load it up.

HTH,

--
Scott
http://www.OdeToCode.com

On Thu, 19 Aug 2004 06:07:02 -0700, Roy
<Ro*@discussion s.microsoft.com > wrote:
My dll file is copied to the
"%windir%\Micr osoft.NET\Frame work\{version}T emporary ASP.NET Files" folder
when I compile my asp.net project. When I run the application. The dll under
this folder is loaded, not the one under bin folder. Why is that? How can I
load the one under bin folder?


Nov 18 '05 #4
Hi Roy:

One alternative is to use a 'satellite assembly' instead of a resource
file. Here is some more info:

http://samples.gotdotnet.com/quickst...aspx#satellite

HTH,

--
Scott
http://www.OdeToCode.com
On Thu, 19 Aug 2004 07:55:02 -0700, Roy
<Ro*@discussion s.microsoft.com > wrote:
I can understand the reason you gave. But it confuses me more since it
complecates the deployment. I have a subfolder with some resource files under
it. This folder is relative to the bin folder, which means I can get the
folder dynamically from my assembly dll under bin folder. If the dll loaded
is the one under temporary folder, I cannot use XCopy to deploy my project.
How can I resolve it?

"Scott Allen" wrote:
Hi Roy:

I believe the ASP.NET team was trying to reduce the number of
scenarios where you have to restart the web application.
If ASP.NET loaded the DLL from the bin folder, the DLL would become
locked. The only way to update the DLL would be to stop the web
application to release the lock and then copy in the new DLL.

The way it works now is ASP.NET makes a shadow copy of the DLLs in the
bin directory. If you slide in a new version ASP.NET will detect the
new file, shadow copy and load it up.

HTH,

--
Scott
http://www.OdeToCode.com

On Thu, 19 Aug 2004 06:07:02 -0700, Roy
<Ro*@discussion s.microsoft.com > wrote:
>My dll file is copied to the
>"%windir%\Micr osoft.NET\Frame work\{version}T emporary ASP.NET Files" folder
>when I compile my asp.net project. When I run the application. The dll under
>this folder is loaded, not the one under bin folder. Why is that? How can I
>load the one under bin folder?



Nov 18 '05 #5
Hi Roy:

Ah! You could just use the MapPath method to get the path to the file.
.. You pass MapPath a virtual path and it will return the physical path
to a file.

If I put:
string s = Server.MapPath( "bin/a.bmp");

My result is:

"E:\dev\xprmnt\ aspnet\Calendar \bin\a.bmp"
Note: you can also use HttpContext.Cur rent.Server.Map Path if you are
in a class library outside of a web form.

HTH,

--
Scott
http://www.OdeToCode.com

On Thu, 19 Aug 2004 10:35:03 -0700, Roy
<Ro*@discussion s.microsoft.com > wrote:
I am sorry I should not use the name "resource files". Actually, they are
picture files such as bmp files. I need to add new files or remove files
frequently. Apparently satellite assembly is not appropriate since it needs
to be compiled. Any other ways to handle this issue?
Thanks.
Roy

"Scott Allen" wrote:


Nov 18 '05 #6

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

Similar topics

5
16768
by: Rosa | last post by:
Hi, I'm trying to clear the TIF on Windows XP programmatically with the below code. This code works fine on any folder but the TIF. For some reason the atEnd() statements always defaults to true and no files are deleted in the folder. The peculiarity of this issue is that the files/subfolders cannot be seen through the windows explorer either. I can only access/delete them through a command shell. Any ideas?
3
6121
by: Jim | last post by:
Is it possible to read the Temporary Internet Files folder using C#? I'm messing with FileIO (newbie here) and everything seems to work fine until I try to read the list of files in this Temporary Internet Files folder. I'm only received 1 file when I know there is more. Any suggestions are very appreciated. Thanks
3
3902
by: Rajiv Das | last post by:
VS 2003, XP SP2 ------------------------------------------------------------ DirectoryInfo temporary = new DirectoryInfo( Environment.GetFolderPath(Environment.SpecialFolder.InternetCache)); FileInfo files = temporary.GetFiles(); foreach(FileInfo fi in files) { Console.WriteLine(fi.FullName); }
2
1370
by: Juleke | last post by:
Hello, For some test, I have setup one computer with Win 2003 Standard + IIS + Active Directory My problem is Access to the path "c:\windows\microsoft.NET\framework\v1.1.4322\temporary ASP.NET Files\...." is denied when I'm trying to use a .NEt application
2
4208
by: Amelyan | last post by:
VisualStudio is trying to copy older version of Company.Interface.dll into runtime directory from C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary ASP.NET Files\ and I get this warning. Warning: The dependency 'Company.Interface, Version=1.0.1940.30685, Culture=neutral' in project 'MyWebApplication' cannot be copied to the run directory because it would overwrite the reference 'Company.Interface, Version=1.0.1940.31541,...
10
3436
by: jojobar | last post by:
Hello, I am trying to use vs.net 2005 to migrate a project originally in vs.net 2003. I started with creation of a "web site", and then created folders for each component of the site. I read somewhere that each folder under the "web site" is compiled in separate assembly. I however, did not find that the "web site" creation in vs.net 2005 created any AssemblyInfo.cs file.
4
28950
by: Anbu | last post by:
Hi all, I have developed an application in VS .NET 2003 (framework 1.1) on a XP platform. It is working fine in that PC. Now, I setup new PC with same configuration for another develper. Whenever I execute the application it gives, Unauthorize Exception error and it's not execting the application property. The Error message is as follows,
2
2678
by: Chris Newby | last post by:
After googling this I got lots of information and tried a few different things. However pages for a particular site are still consistantly failing with "Access Denied to C:\ ... \Temporary Asp.Net ... bla bla bla". Specifically, I created an Asp.Net application on a new 2003 server. It worked at first and while I was fiddling with something else it stopped working. Not able to figure out what the problem was, I deleted the app and...
5
3416
by: rogersw8n | last post by:
Some how, some way the account that creates folders under Temporary Internet files has been changed to a domain account for VS 2003 and VS 2005. I recently installed VS 2005. All seemed to be ok afterwards. I did no development for a couple of weeks, came back and I kept receiving Access Denied to Microsoft.Net\Temporary Internet Files\... Access is Denied. ASPNET had full access to that file and all subfolders. The website I am...
0
8246
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8179
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
8341
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7174
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6112
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4084
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4184
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1796
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1489
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.