How can I compile controls to a single DLL?

C

chambersdon

I have several projects that I need to compile into a single DLL. Is
this possible?

We have a project called 'Utilities' that includes classes to which
encapsulate business logic.
I've now created another project called 'Controls' with custom controls
that can be used by all of our developers. The Controls project has a
reference to the Utilites project because it needs some of this
functionality.
How can I build the Controls project so everything needed is put into a
single dll?

A single dll will make it much easier to manage and simplier to keep
each developers environemnt up to date. Any new developer wuld just
need the out-of-box IDE and one DLL to access our custom controls.
Can the IDE build a single DLL like the old C++ visual studio IDE could
do? I think this was called a 'static dll'. If not, can any of the
command line line tools give me what I need?

Thanks,
Don
 
M

Matt

If you create a Class Library project the output is going to be a dll
that you can use in other projects providing you add references to it.
 
D

Don

I undertstand that. I have a class library project called 'Controls'.
I want to compile 'Controls' into a dll named Control.dll and provide
that dll, and only that dll, to the rest of the team.

Controls has a reference to the Utilities dll so a copy of
Utilities.dll is stored in Controls bin directory. When I compile
Controls I get a Control.dll file but I still need ot distribute
Utilities.dll to the rest of the team. I want everything compiled into
one DLL.
 
T

Tim Wilson

If you have the source for both dlls you could place them in the same
project and compile them together. You would not necessarily need to have
the class files in the same directory as the project as you can always
"link" to the files instead. Or you could use the ILMerge utility to merge
two assemblies together
(http://research.microsoft.com/~mbarnett/ilmerge.aspx). I haven't used this
utility but it should allow you to merge your two dlls together after they
have been compiled. Is it really that big of a problem to distribute two
assemblies? It may allow for cleaner separation in the long run to keep the
utilities assembly and a custom control assembly separate. When the devs
drag and drop an instance of a custom control from the toolbox the design
environment should add a reference to the custom control assembly as well as
its dependencies.
 
C

chambersdon

It is not a huge problem to distirbute everything but i makes it much
easier when new people come to the team. Some of our 'coders' just
hammer out code and don't really understand .NET. They run into dll
problems and get stuck. Not the ideal way to work but I don't have the
power to change it.
 

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

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,045
Latest member
DRCM

Latest Threads

Top