08-28-2008 03:53 AM
Hi,
How can I change flow properties run mode from e.g. normal to skip at runtime ?
I would like to execute my sequence in different measurement instrument setups and running of all sub-sequencies is not possible in certain setups.
I use TestStand 3.5.
regards,
Petri
08-28-2008 05:01 AM
Hi,
Maybe you could use the preconditions property on the subsequence calls, depending on the setup condition.
It's easier than changing the flow property at runtime.
If the precondition is ok, the step is executed.
If the precondition is ko, the step is skipped.
Bruno
08-28-2008 05:22 AM
Thanks, I should go for that if I don't find solution to change the run mode.
In shipped OI, operator has capability to change the run mode in edit time. Benefit, I see, changing the run mode in run time forces the running of sequence to a certain known procedure.
08-28-2008 06:20 AM - edited 08-28-2008 06:22 AM
Hi,
I agree with bruno_p but if you what to change the run mode use the TS API method Step.SetRunModeEx()
Step.SetRunModeEx ( newRunMode, [executionParam])
Sets the run mode of a step.
You can set the run mode either for the sequence file or for a particular execution. If you pass an Execution object for the executionParam parameter, the run mode change only applies to that execution and is lost when the execution is destroyed. If you do not pass an Execution object, the run mode change effects all current and future executions and is saved when you save the sequence file.
newRunMode As String
[In] The RunModes constants define the valid values for this parameter.
executionParam As Variant
[In] [Optional] If you want to set the run mode for a particular execution only, pass a reference to an Execution object.
If you are useing TS4.1 then you can perform TS API calls in expressions therefore you could put your expression in the Step's Pre-Expression or even in the pre-condition.
Hope this helps
Regards
Ray Farmer
08-28-2008 07:04 AM
Thanks for quick response! I can now evaluate the best solution for me.
regards,
Petri