NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Automation Interface cannot be obtained.

Solved!
Go to solution

I am perplexed as to why I cannot obtain the variable value when I supply the variable context as a parameter (VarContext below), but it works when I use the sequence context. I was hoping to avoid the complete lookup string path, but it seems that it must always be from the root sequence context.

It may not seem like a big deal whether it's "Locals.Var" or just "Var", but this is just an example - some of my lookup strings are highly nested and thus very long.

 

Any ideas?

 

Thanks,

Ronnie

 

 

 

CropperCapture[20].Png

 

TestStand 4.2.1, LabVIEW 2009, LabWindows/CVI 2009
Download All
0 Kudos
Message 1 of 3
(3,448 Views)
Solution
Accepted by topic author Believer

Right Click on your VarContext control on the front panel.

Select ActiveX Class>>Browse..

Under Type Library select NI TestStand API x.x.x Version x.x

Under Objects choose PropertyObject

 

You cannot assume that the Locals is the sequence context.  If you open up the TS - Get Property Value.vi you will see that it assumes you are passing the sequence context.

 

Now instead of using the TS - Get Property Value.vi replace that with an invoke node.  Choose GetValNumber as the method to call.

Wire your string constant with Var in it to the LookupString parameter and a numeric constant with 0 in it to the options parameter.

Wire the GetValNumber to your value indicator.

 



You should be good to go now.

Message Edited by ~jiggawax~ on 07-14-2009 11:09 PM
jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
Message 2 of 3
(3,440 Views)

Jigg,

 

Thanks for the help and especially the detailed instructions. It worked perfectly.

Really appreciate it.

 

Thanks again,

 

Ronnie

TestStand 4.2.1, LabVIEW 2009, LabWindows/CVI 2009
0 Kudos
Message 3 of 3
(3,426 Views)