.Net 2.0 b2: Renaming App_Code.dll

G

Guest

During the Pre-compile process of an ASP.Net 2.0 app, it compiles the
code-behind & optionally the presentation files into an assembly named
App_Code.dll. Can that not be renamed to a more project friendly name, such
as ProjectName.dll or something. I didnt see any parameters to be able to
choose the output assembly name.
 
S

Scott Allen

App_Code.dll will contain just the code from underneath the App_Code
directory.

A webform and it's code-behind will now compile into the same
assembly, and that assembly will be a different assembly than
App_Code.dll.

Any non-trivial ASP.NET 2 site will produce more than a single
assembly, which is why they don't have the output name as an option.
 
G

Guest

When I precompile my VS2005 Web Service the only assembly created for me in
App_Code.dll. Disassembling it, it does contain my service's code-behind.
Since all code will likely sit in App_Code directory & it gets all compiled
into App_Code.dll, why not have the ability to name the assembly
appropriately. This is not very different from version 1.1 where you could
choose the assembly name.
 
S

Scott Allen

Well, the purpose of App_Code is to give web projects a well known
location where you can drop in source code files and let the runtime
compile them on the fly.

It's assumed all the webforms and user controls will want to use code
from the well known location, so the resulting assembly needs a well
known name for the runtime to establish a reference.

If you want a little more control over the situation, you'll have to
use a class library for class files.

Is this an asmx web form you migrated from 1.1? I'd think the
migration wizard would have migrated the code-behind to a partial
class.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top