NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

View Step Name And Unique Step ID

Hello everyone,

 

I have a lot of sequences that contain Do While loops and the Do While Loop Condition is based on the Result.Status == "Failed" of several steps within the Do While loop (and a limiting loop iteration limit of course). The headache is that I really like using the Unique Step ID as the reference to the step (for example ThisContext.RunState.Sequence.Main["ID#:ODsqiaac7RGqDQCALyLRfB"].Result.Status == "Failed") but this makes it very difficult to double check that I've selected the correct steps fo the Loop Condition unless I open the Expression Browser Dialog Box and it then prints ThisContext.RunState.Sequence.Main["ID#:ODsqiaac7RGqDQCALyLRfB"/* Unique Id of 'PS_Adjustment_Readback_02' */].Result.Status == "Failed".

 

Is there any setting I've missed to which will force TestStand to print the step name with the unique ID in the workspace Loop Condition box and/or in the Description box so that I don't have to open the Expression Browser? Note that the If Condition Expression seems to do this just fine...

 

Thanks!

0 Kudos
Message 1 of 10
(5,161 Views)

Hello,

Have you tried to monitoring the sequence status.. TestStand API to Monitor Sequence File Status 

 

or maybe you try with more options like... Which Variable Contains the TestStand Sequence Status? 

 

and then scan through the status that have executed in that run...

Is this something that helps or do you need more info from the steps on the body of the sequence?

Is the ID useful for other purpose other than scanning step status?

CLA, CTA
0 Kudos
Message 2 of 10
(5,132 Views)

Thanks for the reply LFBaute, but that's not exactly what I'm asking.

 

The issue is really that during sequence editing I would like to see both the Unique Step ID and the step name side by side in the Expression editor box. At runtime my sequences work without any issue, it's just for editing visualization purposes that I would like to see both pieces of information.

0 Kudos
Message 3 of 10
(5,125 Views)

Ok, got it now, no problem

CLA, CTA
0 Kudos
Message 4 of 10
(5,116 Views)

I tried this out. Both the If and DoWhile do not display the step name in the edit box unless you use the expression browser dialog.

 

The only difference I see is in the description column.  Let me know if that is not what you see.

 

The difference is because the If step's description expression contains: 

Str(LocalizeExpression(Step.ConditionExpr), "%expr", 0x7)

while the DoWhile's contains only:

 

LocalizeExpression(Step.ConditionExpr)

 

 

This looks like an oversight. I'll enter a bug report, thanks.

0 Kudos
Message 5 of 10
(5,109 Views)

James,

 

You're correct, the only place I actually see the step name is in the If step description and in the Condition Builder dialog box. I also see the step name in the Precondition "preview" box to the right in Step Settings. I do not see the step name in any of these steps Expression box.

 

So if I understand you correctly, it's not a setting or anything I can change since it's a step type property or something of that nature. 

0 Kudos
Message 6 of 10
(5,101 Views)

I found how to change it... you are looking for this, right ?

LFBaute_0-1674761343157.png

 

here it goes...

 

Run through this procedure for enabling hidden properties.. Display the Unique Step ID of TestStand Steps

and then continue 

1. Right click on Sequence Pane Column Titles

LFBaute_1-1674761368315.png

 

2. Then Right Click on Step List Configurations / Edit Step List Configuration...

3. Add a New Configuration on the left side ... "Select Configuration for Viewing Files"

LFBaute_4-1674761708890.png

 

4. In the Columns tab add another Custom Property...in this case select it as..

 

Type: Expression

Expression: Step.TS.id

 

This will popup

LFBaute_3-1674761526875.png

 

 Click OK and then OK again to close Step List Configuration Box

and make sure to have New Configuration Enabled.

LFBaute_5-1674761824597.png

 

 it should look close to this

 

If you reorder them, in the "New Configuration" Step List Configuration, you can view them as

 

LFBaute_0-1674762104636.png

 

 

 

 

CLA, CTA
0 Kudos
Message 7 of 10
(5,099 Views)

Actually, I would prefer if I didn't see the unique step ID at all, and just the name in the column just as James indicated is true for the IF step description.

 

You did give me an idea though. I tried creating a new column for my step list configuration and specified it by an expression Str(LocalizeExpression(Step.ConditionExpr), "%expr", 0x7) since that's exactly what James said is being done for the If step type. I notice that when I apply this new column I do in fact get the step names of the Do While condition expression listed! But unfortunately TestStand is complaining about other steps not knowing what Step.ConditionExpr is because they don't have that property. So close! I'll admit it really wouldn't be the ideal solution anyway because adding another column to the editor isn't going to make it easy to read.

0 Kudos
Message 8 of 10
(5,085 Views)

You can potentially add a property checker to your Expression...

 

PropertyExists("Step.ConditionExpr") ? (Str(LocalizeExpression(Step.ConditionExpr), "%expr", 0x7) ) : ("")

 

and obtain something like this...

 

LFBaute_3-1674767803045.png

 

Take a look at the DoWhile Expression Box at the bottom

And the results are printed on the second StepID..

and remove the first StepID Column...I just left it there to read all of them

CLA, CTA
Message 9 of 10
(5,077 Views)

I haven't been able to try your latest post, but from the looks of it that's exactly what I'm trying to achieve. I'll reach out once I can try it. Thanks!

0 Kudos
Message 10 of 10
(4,963 Views)