Re: Remote call to COM impersonating another user
- From: "Nicholas Paldino [.NET/C# MVP]" <mvp@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 7 Jan 2008 10:17:56 -0500
Well, you are more than likely going to have to call through DCOM/COM+.
Assuming you have it set up correctly on the other machine, and you have an
interface definition for the COM object you want to call, you can call the
GetTypeFromProgID (or GetTypeFromCLSID), using the overload which will take
a remote machine name. You would then create an instance of that type
through a call to CreateInstance on the Activator class, and cast to your
interface type.
Mind you, the semantics of making a remote call are different than just
making a regular COM call (activation contexts, instancing, and the like).
Do you already have the object set up for remote calls?
--
- Nicholas Paldino [.NET/C# MVP]
- mvp@xxxxxxxxxxxxxxxxxxxxxxxxxxx
"JCav" <jcavanaugh@xxxxxxxxxxxx> wrote in message
news:47823515$0$9535$4c368faf@xxxxxxxxxxxxxxxxx
I need to call a COM object from a remote machine using C#. I also need to
pass on a different userID and password to the call. Has anyone done this?
I've used Java to do this using JIntegra, but the application I'm using
requires .NET.
Any advice?
.
- Follow-Ups:
- References:
- Prev by Date: Re: Need help creating another XML file
- Next by Date: newbie: Getting Program Files folder in Windows Mobile 6.0
- Previous by thread: Remote call to COM impersonating another user
- Next by thread: Re: Remote call to COM impersonating another user
- Index(es):
Relevant Pages
|