NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Obtaining Subsequence Step Pass/Fail Status Within Main Sequence

When in the Main Sequence, how can I find the PASS/FAIL status of a step within a subsequence step that has already run?  

 

I know within the same sequence you can find this by using the following instruction:

RunState.Sequence.Main["ID#:"].Result.Status == "Failed"

 

How can I read a subsequence steps status within the main sequence?

 

Thanks!

0 Kudos
Message 1 of 6
(5,618 Views)

If you now ID of the step in subsequence, I guess that you can do the following:

  1. Get ResultsList array from Main sequence.
  2. Search for subsequence call ResultsList array (by ID of subsequence).
  3. Get result of the step, by its ID, from ResultsList array of subsequence step.

The easier workaround is to save result of that step to some FileGlobals variable, value of which you can access from the Main sequence.

But the question is, whether you really need it. What is your goal, please? Why do you need to know result of that particular step?

If step will fail, then subsequence will fail - so you'll know it from main sequence.

The same is when step will pass...

 

Sincerely, kosist90

 

logos_middle.jpg

 

Check out new feature of LabVIEW 2017!

Message 2 of 6
(5,587 Views)

kosist90, thanks for the reply.

 

Here's my issue:

 

In a the main sequence, I call a subsequence.  

 

Within that subsequence, I have the following steps:

1. Pass/Fail Step: Using a Dialog Box VI, the operator is asked a YES/NO question.  This dialog box also has a button on it to Abort the subsquence which if abort is selected I have the step run the subsequence cleanup and then the main sequence cleanup (which is needed to reset certain equipment).

2. Numeric Test Step: Voltage Reading

 

I want the main sequence to be able to recognize if the P/F step ABORT button was pressed in the subsequence or a subsequence step failed (P/F step or Numeric Step failed) to jump to the cleanup in the main sequence.

 

I know in the main sequence you can set a post action within the subsequence call to jump to cleanup if the subsequence failed or goto next step if the subsequence passed.  How do I create the post action of the subsequence to jump to the main sequence cleanup if the abort button was pressed or one of the subsequence steps failed?  Thanks for your help.

0 Kudos
Message 3 of 6
(5,553 Views)

My answer will be similar to the answer on the other topic, what you've asked here on the forum.

I'd do the following:

  1. Check, what button was pressed.
  2. If it was not Abort button, continue to test.
  3. If it was Abort, go to "simulated failure" step. Then, subsequence will fail, and go to Main sequence cleanup (if you've set up post actin for subsequence call step).
  4. If test step will fail, it'll also go to subsequence cleanup, and to Main sequence cleanup section.

I attach screenshot, and small seq. example (converted from TS2016 to TS2014). Hopefully, that it could help you...

Subsequence.PNG

 

Sincerely, kosist90

 

logos_middle.jpg

 

Check out new feature of LabVIEW 2017!

Message 4 of 6
(5,546 Views)

kosist90,

 

Thanks for the quick reply.  I have Test Stand 2013.  Could you save the .seq file in 2013 format?

 

0 Kudos
Message 5 of 6
(5,542 Views)

Sure, here you are:

 

Sincerely, kosist90

 

logos_middle.jpg

 

Check out new feature of LabVIEW 2017!

Message 6 of 6
(5,538 Views)