NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to return values from subsequence calls?

Solved!
Go to solution

I want to call a subsequence. I pass in parameters to this subsequence but I also want to have return values. Is there any way to return values other than using globals?

 

-Pat

Message 1 of 4
(7,059 Views)
Solution
Accepted by topic author PT5000
Hi,


You can set the parameter to be 'Pass By Reference'. Right mouse click on the Parameter you are interested and you should find this setting.

Regards
Ray Farmer
Regards
Ray Farmer
Message 2 of 4
(7,052 Views)

Thanks for this. Just to clarify, you sepecify how the variable are passed in the sequence file that you are calling. Thanks again for the help!

 

-Pat 

Message 3 of 4
(7,046 Views)

To change a parameter from "pass by value" to "pass by reference," you must go to the subsequence and right click on the parameter name. The pop-up menu will allow you to select or deselect the "pass by reference" option. You will then see "(By reference)" in the type column and "by reference" in the "how passed" field of the step settings of the calling sequence.

 

You cannot change this by right clicking the parameter name or "how passed" field of the step settings in the main sequence (or calling sequence).

 

I apologize for posting to an old thread, but I had a frustrating time finding this little detail and didn't know where else to share it.

 

 

Best Regards,

 

Sam Broyles

0 Kudos
Message 4 of 4
(483 Views)