NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a method to list all locals, params?

I am accessing the "SequenceContext" type to get a PropertyObjectPtr at run-time in my c++ dll.

I'm going to set test result data directly into Test Stand "locals" at run-time.

Is it possible to call a method that lists all of the "locals" and "Parameters" defined in the active Test Stand script as a string?
0 Kudos
Message 1 of 3
(3,530 Views)
Hi,

The TestStand API doesn't provide a single method to list all the subproperties of a property object.
But it provides instead a set of methods to be used with the run-time property objects:
- PropertyObject.GetNumSubProperties
- PropertyObject.GetNthSubPropertyName
- PropertyObject.GetSubPropertyIndex
By using the methods above you can create the list of all of the "locals" and "Parameters" sub-properties at run-time.

Hope this helps,
Silvius
Silvius Iancu
Message 2 of 3
(3,530 Views)
Hi,

Using your SequenceContext you can get a reference to The Locals or the Parameters within your sequencefile.
Using the Newly obtained reference to either Locals or Paramters you can obtain the Number of SubProperties by using the PropertyObject.GetNumSubProperties.
Using this Number Of SubProperties you can then make repeated calls to PropertyObject.GetNthSubPropertyName to build up an array of strings which contain the names of all the Locals or Parameters within your sequence File.

Hope this helps
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 3 of 3
(3,530 Views)