C
Christopher H. Laco
Long story longer, I'm tearing my hair out trying to get some of my
assemblies to work in ASP/COM. I have 4 classes/assemblies:
#1. CustomerMembershipProvider (Inherits MembershipProvider)
#2. CustomTcpClient (Inherits TcpClient)
#3. ASPFormsAuthentication (does magic to read/write
FormsAuthenticationTickets in ASP 3.0)
#4. ASPMembership (does magic to use Membership API within ASP 3.0)
Now, all of these assemblies are set to "Make assembly COM-Visable" and
"Register for COM Interop". Everything build and registers just fine.
Now, from with ASP, I can Server.CreateObject #3 and #4.
Server.CreateObject for #1 and #2 simply yield me:
While the ASPMembership class can be created under COM, the minute it
trys to return a CustomMembershipProvider from itself, the page also
bails with the same error above.
Now, after some tinkering, I noticed the common ground here is that #1
and #2 Inherit something else while #3 and #4 don't.
Clearly there is some COM Interop/InteropServices/Inferace magic I'm
missing. What do I have to do to get these things expoed to COM and
actually working?
It is just the fact that the auto generated iterop stuff doesn't guess
correctly, and I should build and interface for those classes that
inherit other things so .NET knows what to expose?
-=Chris
assemblies to work in ASP/COM. I have 4 classes/assemblies:
#1. CustomerMembershipProvider (Inherits MembershipProvider)
#2. CustomTcpClient (Inherits TcpClient)
#3. ASPFormsAuthentication (does magic to read/write
FormsAuthenticationTickets in ASP 3.0)
#4. ASPMembership (does magic to use Membership API within ASP 3.0)
Now, all of these assemblies are set to "Make assembly COM-Visable" and
"Register for COM Interop". Everything build and registers just fine.
Now, from with ASP, I can Server.CreateObject #3 and #4.
Server.CreateObject for #1 and #2 simply yield me:
Server object error 'ASP 0177 : 80131509'
Server.CreateObject Failed
/Default.asp, line 35
80131509
While the ASPMembership class can be created under COM, the minute it
trys to return a CustomMembershipProvider from itself, the page also
bails with the same error above.
Now, after some tinkering, I noticed the common ground here is that #1
and #2 Inherit something else while #3 and #4 don't.
Clearly there is some COM Interop/InteropServices/Inferace magic I'm
missing. What do I have to do to get these things expoed to COM and
actually working?
It is just the fact that the auto generated iterop stuff doesn't guess
correctly, and I should build and interface for those classes that
inherit other things so .NET knows what to expose?
-=Chris