Why is this assembly a temporary asp.net dll?
I have precompiled my web site project into a single dll for the whole site. When I run a page and look at:
Assembly.GetAssembly(this.GetType(开发者_Go百科))
It is resolving as : App_Web_qgqyxtge
But when I make a call to:
Assembly.GetExecutingAssembly()
This resolves to :
Upload, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
I'm struggling to see why the assembly of the page I am looking at looks like a temporary asp.net dll and not the compiled dll that seems to be executing the current code?
That's probably because you are using a Web Site project in contrast to Web Application project and all classes stored in your App_Code
folder will automatically be compiled into temporary assemblies.
Are you running the page in debug mode when you print out that message. The compilation model is different between release and debug. In deug there is on assembly pr page, so I would guess your page is called "Upload.aspx"
精彩评论