LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting the value of an array control from ActiveX

Solved!
Go to solution

When controling a VI through ActiveX, how is it possible to set the value of an array control ?

 

With numerical controls, I have no trouble: I just use SetControlValue and it works well:

vi.SetControlValue('y', 4) for instance.

 

However, when trying to do the same with an array, the value of the control becomes an empty array:

vi.SetControlValue('arr', [3 4 5]) for instance.

 

What is the right way to do this ?

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

Are you using ActiveX in some other programming language and want to change the array control?

 

Your notation isn't something I am familiar with.

0 Kudos
Message 2 of 4
(2,817 Views)
Indeed, I am trying to set the value of the array control through Matlab. See http://stackoverflow.com/questions/9327101/setting-the-value-of-an-array-control-of-a-labview-vi-thr... for a detailed illustration.
0 Kudos
Message 3 of 4
(2,814 Views)
Solution
Accepted by topic author calvintiger

Hi Calvin,

Have you tried passing the input as a string and converting it to an array?  You may also want to try using a "matrix" control, rather than an array, as they are handled a bit differently. 

Tom L.
0 Kudos
Message 4 of 4
(2,788 Views)