J
jason
i have a C# class library full of objects.
the immediate need was to instantiate these objects in classic ASP, so
i inherit ServicedComponent and build the project with COM Interop set
to true. and the objects work in classic ASP just fine.
however, we are slowly introducing ASP.NET code, and i would like to
make use of the same objects. however, i don't want to use the old COM
method of Server.CreateObject(). i would like to use Import/using
statements to gain access to everything in the namespace.
but when i try add a reference to the .NET application for the class
library, it says:
A reference to 'MyLibrary' could not be added. Converting the type
library to a .NET assembly failed. Type library RCObjects was exported
from a CLR assembly and can not be re-imported as a CLR assembly.
it seems amusing that it can import a COM library into .NET, so long as
the COM library wasn't originally coded in .NET.
so my question is, what's the most appropriate way to make this library
available to both the classic ASP and ASP.NET code?
thanks for any help,
jason
the immediate need was to instantiate these objects in classic ASP, so
i inherit ServicedComponent and build the project with COM Interop set
to true. and the objects work in classic ASP just fine.
however, we are slowly introducing ASP.NET code, and i would like to
make use of the same objects. however, i don't want to use the old COM
method of Server.CreateObject(). i would like to use Import/using
statements to gain access to everything in the namespace.
but when i try add a reference to the .NET application for the class
library, it says:
A reference to 'MyLibrary' could not be added. Converting the type
library to a .NET assembly failed. Type library RCObjects was exported
from a CLR assembly and can not be re-imported as a CLR assembly.
it seems amusing that it can import a COM library into .NET, so long as
the COM library wasn't originally coded in .NET.
so my question is, what's the most appropriate way to make this library
available to both the classic ASP and ASP.NET code?
thanks for any help,
jason