FRIDAY, APRIL 06, 2007
Registering .NET created COM objects for ASP
You cannot use regsvr32.exe to register a COM object that was created using .NET (It is possible to create COM objects in .NET, btw).
I do not know what happens if you try; I skipped that blunder.
You use the regasm.exe program, which mimics certain required COM functionality and registers the dll file. However, if you just run regasm.exe ASPemail.dll it will say that it worked, but when you try and actually instantiate it in ASP, it will fail:
Server object error 'ASP 0177:80070002'
The call to Server.CreateObject failed.
You are missing a critical switch, codebase. I don't know exactly what it does, but it fixes the problem. Just run: regasm.exe ASPemail.dll /codebase and try it again.
This assumes that you are calling the correct ProgID, you can set that as an attribute on your class, or you can just let the compiler set it for you (it will be Namespace.AssemblyName).
Posted by Chet at 7:00 PM
Post a Comment
Feel Free To Share Your Thoughts
You can use [b], [u], [i], and [url]
More About Me
Philosophy for Understanding Theology
20,000 Leagues Under the Sea
Settlers of Catan
Misc Arduino projects