Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Help - COM+ / C#

3 views
Skip to first unread message

douglas kruse

unread,
Mar 5, 2002, 5:42:10 PM3/5/02
to
1) I've written a component in C# and registered it in both GAC
(gacutil) and COM+ (regsvcs) without a problem. I can open up both
COM+ and the assembly and see that it's there. I also do have the
*.snk referenced in my assembly.

2) Now I go into VS.Net and attempt to write a simple C# console app
to test it..I see the component listed in the "Add Reference" window
(under COM tab). I select it and get the following error:

"A reference to 'a database manager component' could not be added.
Converting the type library to a .NET assembly failed. Type library
clsDBManager was exported from a CLR assembly and can not be
re-imported as a CLR assembly."

Right now the only way I can reference the COM+ component is to
reference the file (dll) directly. It works but I know I'm missing
something simple..also, it doesn't appear the component in COM+ is
really working (no spinning?).

I've also looked at http://support.microsoft.com/default.aspx?scid=kb;en-us;Q306296&id=306296&SD=MSKB
, it's valuable info up to "Test Your Component", then it falls apart
and doesn't answer this question.

Thanks!

-doug

Bobby Mattappally [MS]

unread,
Mar 5, 2002, 6:17:37 PM3/5/02
to
Doug,

You should add the Reference from the .Net tab, since it is a .Net
Component.
When you try to add it from .COM+ tab, you are trying to do a two stage
interop.

.NET componet -> COM+ -> .Net Callable Wrapper-> .NET Client.

where as all you need is:
.Net componet ->.Net Client.

Hope this makes sense.

Thank you,
Bobby Mattappally
Microsoft Developer Support

This posting is provided "AS IS" with no warranties, and confers no rights.
Got .Net? http://www.gotdotnet.com

Are you secure? For information about the Microsoft Strategic Technology
Protection Program and to order your FREE Security Tool Kit, please visit
<http://www.microsoft.com/security>.


--------------------
>From: doug_...@hotmail.com (douglas kruse)
>Newsgroups: microsoft.public.dotnet.languages.csharp
>Subject: Help - COM+ / C#
>Date: 5 Mar 2002 14:42:10 -0800
>Organization: http://groups.google.com/

douglas kruse

unread,
Mar 5, 2002, 7:51:47 PM3/5/02
to
thanks for the reply. Your post makes perfect sense..although my
component doesn't show up in the .NET reference window, only COM. ?

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Bobby Mattappally [MS]

unread,
Mar 5, 2002, 8:48:43 PM3/5/02
to

--------------------
>From: douglas kruse <doug_...@hotmail.com>
>References: <AR6qcvJxBHA.2040@cpmsftngxa07>

>
>
>thanks for the reply. Your post makes perfect sense..although my
>component doesn't show up in the .NET reference window, only COM. ?
>

It doesn't get added there automatically.
You can use the browse button to browse to the directory of the assembly
and add it.

See below if you really need to add it to the .Net tab:
http://support.microsoft.com/support/kb/articles/q306/1/49.asp

Hope this helps.

douglas kruse

unread,
Mar 5, 2002, 9:07:47 PM3/5/02
to
cool..thanks!
0 new messages