LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ActiveX CIN

Solved!
Go to solution

Hello, Rolf,

 

I agree with you to 100% again.

 

We work in LabVIEW 8.5.

 

I already did a protection of the LabVIEW product using CINs. It's very easy and not takes long time, but there were no ActiveXs there.

 

However, it is a pity, that it is impossible to pass a pointer to ActiveX to CIN.

 

Great thank you,

Evgan

0 Kudos
Message 11 of 15
(1,065 Views)
Solution
Accepted by topic author evgan

It is very easy to pass a pointer to ActiveX to CIN.

Register the pointer in the GIT (Global Interface Table) and pass its cookie to CIN.

Inside CIN it is possible to pull out the pointer using the cookie from GIT.

For explanation look "IGlobalInterfaceTable' interface in Help.

 

Evgan

 

0 Kudos
Message 12 of 15
(1,023 Views)

Another method is to abandon the CIN idea and use a DLL instead. In the parameter configuration for Call Library Node in at least LabVIEW 7.1 and later you can configure a parameter to be an ActivX Refnum and define if LabVIEW should pass the IDispatch or IUnknown interface pointer to the DLL.

 

Using the GIT is certainly another idea, but for the purpose of passing parameters inside the same application a somewhat heavyweight aproach. Also I believe that using the GIT has some implications in terms of lifetime control of an object and a possible performance penalty since the objects are actually marshalled in order to be able to get passed between processes.

Message Edited by rolfk on 04-21-2010 03:18 PM
Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 13 of 15
(923 Views)

My ActiveX works in the other process.

 

Evgan

0 Kudos
Message 14 of 15
(906 Views)

evgan wrote:

My ActiveX works in the other process.

 

Evgan


Then GIT might be a solution, as well as using an IDL generated ActiveX interface library that takes care about marshalling data through RPC. For the purpose of the original post this would be however not important.

Message Edited by rolfk on 04-21-2010 03:39 PM
Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 15 of 15
(904 Views)