NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

access step name in labview

Is there any way to access the name of the current Step, as a string, in LabVIEW using the Sequence Context?
LV 8.2.1
WinXP
0 Kudos
Message 1 of 8
(3,973 Views)
I've had to change the name of a step at runtime. What I did was to use the ActiveX adapter to get the step name and write it to a local variable. Runstep.Sequence.Main(name of step you want, I used the unique ID). Configure the step for the TestStand API and the Object class should be Property OBject. Check call method. The action should be Get Property and the property should be Name. Create your local variable under the value column and this you can then use for your LabView code. Hope this helps.
Now Using LabVIEW 2019SP1 and TestStand 2019
0 Kudos
Message 2 of 8
(3,969 Views)
Thank for you for input. I'm pretty new with both Teststand and LabVIEW. I didn't do exactly as you mentioned but I got what I wanted. I took a lot of research direction from your description and looked into the ActiveX properties. I was able to extract the Step name using Propery Nodes of the Sequence Context. The Teststand help document for "Accessing TestStand Objects Inside Other TestStand Objects" had a code example that I changed to fit my needs. Thank you again for your help in directing my where to look.
LV 8.2.1
WinXP
0 Kudos
Message 3 of 8
(3,964 Views)
Hi,

Here's a labview VI that may help.

It obtains the Sequence Name from where the step was called, The Step name, and the full path from top level sequence to the step. eg if a step, "Action" was called from the process model and the step is in the MainSequence. the Resultant string would be MainSequence Callback->MainSequence->Action.


Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 4 of 8
(3,958 Views)
Sorry, I'm using LabVIEW 7.0.
LV 8.2.1
WinXP
0 Kudos
Message 5 of 8
(3,953 Views)
Hi,

Try this. Hope its save to version 7.0 ok

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 6 of 8
(3,945 Views)
Thank you, it opened just fine. I ended up using pretty much the exact code from that example, a small part anyway. How important is it to close the references to the Sequence Context?
LV 8.2.1
WinXP
0 Kudos
Message 7 of 8
(3,941 Views)
Hi,

Its good practices to tidy up, after you have finished, but dont close the SequenceContext reference you pass into the VI, only those you derive from the main reference.

I surpose you could end up with a small memory leak for each un-closed reference. Which could be come a large leak depending on how many times your VI's get called before your application is closed.


Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 8 of 8
(3,937 Views)