Ben Luckham
10/8/2002 12:47:00 PM
Hi,
I am trying to compile a library that has been written
partially in VB and partially in C#. To do this, I have
compiled the classes as a series of modules. I am trying
to merge these modules into a single .dll file that I can
use in a Visual C# project.
To do this, I have linked the modules into a single
assembly using the assembly linker, as follows:
al /target:library /out:MyLibrary.dll Module1.netmodule
Module2.netmodule Module3.netmodule
Having added a reference to this .dll in my Visual C#
project, the project compiles OK. However, when I try to
run it, I get a System.TypeLoadException, complaining that
it cannot load one of the types contained in of
the .netmodule files I linked together.
I have used the ildasm tool to inspect the .netmodule
files, and they describe their types/classes OK. I used
the same tool to inspect the .dll, only to find that it
does not describe any types/classes at all... is this
correct?
Another thing I have noticed is that the application is
trying to load version 1.0.1011.20614 (or whatever) of the
assembly, although the version number shown when
inspecting the .dll in ildasm is 0.0.0.0. I have tried
removing/adding the reference to this .dll with no effect.
What the heck is going on?!
All I want to do is merge the three .netmodule files into
a single assembly... what am I doing wrong?!
Thanks,
Ben Luckham.