LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to conect to remote ActiveX (COM) program

Hi everybody.

I want to comunicate between LabView and another program by using ActiveX (COM).
If both - LabView and the other program is at my local machine - everything is fine.
I use the "Automation Open"-VI to open the ActiveX conection.

The problem is that if the other program is located at another PC (inside network) the "automation Open" -VI returns an error.

How can I get an ActiveX connection to the other PC?

Thanks for help.

Best regards.

Ronny

Message Edited by rfriedr1 on 05-23-2005 10:00 AM

Message 1 of 5
(3,142 Views)
What is the error value you are getting back?

My guess is that it is likely to be E_ACCESSDENIED (0x80070005 or 0x80000009) because getting COM to work across a network is a never ending challenge. You have to get all of the DCOM NT permissions set up correctly, make sure the proxies, if necessary, are installed, etc.
0 Kudos
Message 2 of 5
(3,129 Views)
Hi Brain,

thanks for your answer.

My problem in the moment is of more basic nature.
In the moment I have no idea how to establish a connection to the remote PC via network and LabView. The PC is running in our Network and I have acces to it. But, is it that easy that I give just the right machine name at the "Autimation Open"-VI and thats all?
What do I have to do at the remote PC. The program I want to have ActiveX access to is running there. Is that all what I have to do?

Regards.

Ronny
0 Kudos
Message 3 of 5
(3,119 Views)
I'm afraid it isn't quite that easy. From LV all you need to do is specify the machine name to get the remote access. However, in order for that to work, all of the COM stuff must be configured correctly for remote access (DCOM) and all the security settings must be done correctly. And if you are running XP SP2 or 2003 Server, there are additional steps to take because those OS's have tightened up security and thus have additional steps to get it to work.

SUMMARY
=======
If you don't know much about COM or don't have access to a COM guru that created the COM component you are trying to use, you might want to think about creating a little LV app that runs on the remote box and then use LV networking to remotely access it. DCOM isn't impossible, but it isn't easy - especially if you don't have a good grounding in non-LV COM interfacing.

DETAILS
=======

Is the COM object you are trying to access a home grown one or 3rd party? Are the two computers both in the same NT Domain or are they in Workgroup configuration? DCOM uses NT security and thus you typically need to have both computers in the same domain and using a domain credential for communication.

I'm afraid I can't give you step by step instructions on how to do this (I haven't needed to use DCOM in about 6 years) - but there are a lot of resources out on the web and books like Don Box's "Essential COM" walk you through most of it. For example, here are some references to look at

http://support.microsoft.com/kb/176799/EN-US/
http://support.microsoft.com/kb/158508/EN-US/

Oh, and this might be handy - ran across this while looking for links for you...

http://support.microsoft.com/default.aspx?scid=kb;en-us;249726
Message 4 of 5
(3,113 Views)
Thank Brain,

I'm not surprised that it not that easy.
Because I'm not familiar with DCOM I will follow your advice to write a little program that will do all of the ActiveX stuff directly at the remote PC and then send it to the other PC where the LabView program is running.
Unfortunately there's not enough time to learn more about DCOM. I have to prioritise...

Thanks for help.

Regards.

Ronny
0 Kudos
Message 5 of 5
(3,106 Views)