Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8455841
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T12:23:26+00:00 2026-06-10T12:23:26+00:00

I have a COM dll which I was using in my .net project through

  • 0

I have a COM dll which I was using in my .net project through interop referance. Now I got a requirement to move this COM component to another remote machine and create instance there.(kind of out of machine similar to out of process, probably this is remoting, i don’t know :-))

What I have done was created a new COM+ applciation in server machine. Added this component inside this app. This is how it is listed in COM+ interface on server.
enter image description here

Exported this app as proxy insatller and installed in my client machine. Used following code to
access this

Type type;
type = Type.GetTypeFromProgID("DllName.COMName", "serverName", false);
var COMObject = Activator.CreateInstance(type);
var returnValue = COMObject.GetType().InvokeMember("Method_1",   BindingFlags.Public |  BindingFlags.InvokeMethod, null, COMObject, new object[1] { "1" });

But I am getting UNKNOWN NAME (0x80020006) error when invoking Method_1? Have any one face similar issue before, please help me.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T12:23:28+00:00Added an answer on June 10, 2026 at 12:23 pm

    What I would do is this:

    1) create an equivalent interface in C#, something like this:

    [Guid("<the interface IID goes here>")]
    public interface ISomeInterfaceName
    {
       int Method1(...);
       int Method2(...);
       int Method3(...);
       ...
    }
    

    2) and then this, instead of your initial late-binding code:

    Type type = Type.GetTypeFromProgID("DllName.COMName", "serverName", false);
    var COMObject = Activator.CreateInstance(type);
    var if = (ISomeInterfaceName)COMObject;
    if.Method1(...);
    

    NOTES: the IID must the IID from the interface, not to be confused with the CLSID. The methods should be laid out to correspond exactly to the COM ones (the methods order is important, how parameters and return type are defined is also important)

    You could also import the TLB from the COM component, if you have a lot of classes and intefaces like this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a COM inproc DLL that we are using in our product. Now
I have upgrade my MVC2 project to MVC3 using this tool: http://blogs.msdn.com/b/marcinon/archive/2011/01/13/mvc-3-project-upgrade-tool.aspx Which is
I have a .NET dll which has some interfaces\classes which are exposed to com.
I have .NET 3.5 web application which uses some COM dll created in VB6.
I have a C++ dll which implements several COM interfaces, that I'm trying to
I have written a COM dll, and wish to register it using regsvr32 myComdll.dll
I have a win32 COM dll. I want to register this dll for different
When you interface a COM object from .NET code, VS creates an interop DLL,
I have created a C# COM DLL which is essentially an enhanced progress bar
I have a wrapper managed application(.net) over a COM Component(created using vb6) where Com

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.