LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Get FrontPanel Control references via ActiveX

Solved!
Go to solution

Hi,

 

I've tried to get references to frontpanel controls via LabVIEW ActiveX server, equivalent to this LabVIEW code:

ActiveX.png

 

but I cant find the ActiveX methods / propertis to use.   Is there a way to do this?

 

/LeifS

0 Kudos
Message 1 of 4
(2,617 Views)

Well, you are right so far. The output of the Controls[] properety is an array of references to the controls and indicators on the front panel. The thing to remember is that these are generic control references so if you want to do things that are specific to a particular class of control (like set the Strings[] property of a ring) you will need to cast the generic reference to a specific one.

 

Mike...

 

PS: Remember to close all your references when you are done with them.


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 4
(2,614 Views)

Well, my question wasn't about how to do it within LabVIEW, but rather how to do the same thing from outside LabVIEW, via ActiveX, from say a C++ program or any other ActiveX compatible language.

I just cant find the corresponding ActiveX properties/methods to do the same procedure as in the picture...

 

 

EDIT:  According to this thread it seems that this functionality isn't exposed via the ActiveX interface.  Correct?

0 Kudos
Message 3 of 4
(2,601 Views)
Solution
Accepted by LeifS

The ActiveX Automation Server interface to the LabVIEW VI server only exposes a very small subset to the actual LabVIEW VI server. Basically it is enough to load and execute particular VIs and pass values to front panel controls by their label name, but that is it.

 

The reason is twofold. When VI Server was introduced in LabVIEW around LabVIEW 5.0 this was mostly the functionality that VI server exposed altogether. There was no scripting at all, and only limited access to the object hierarchy of the frontpanel controls. Even then the ActiveX interface did not expose all methds and properties of the VI server, partly because exposure of LabVIEW internas would have required an extensive ActiveX typelibrary, partly because it was not considered a main concern to be able to do more than launching VIs through it. It was better than the DDE interface already by a long stretch.

 

VI server was then extended enormously in later releases, but the ActiveX interface was not really changed much, also because Microsoft had announced .Net and declared the ActiveX hype of a few years earlier to be deprecated anyways.

Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 4 of 4
(2,580 Views)