07-01-2011 01:49 PM
Hi,
I have setup a COM interface for TestStand(TS) to run certain scripts in TestComplete (TC). Normally, when TestComplete finishes executing the script, it returns a 0 or 1 to denote pass/fail in the TestStand step (e.g String value test step). This worked fine.
However, now I need TestComplete to return a vaule( e.g 32) to TS, and TS need to evalue this value in a while statement. So if TC return value is 32, I'd have some statement in TS ike :
While (return value != 30)
Do something..
Thanks,
Solved! Go to Solution.
07-01-2011 02:38 PM
There are a hundred ways to implement what you are asking. The hard part is deciding which one would be the best for you.
What adapter are you using to communicate with TestComplete? ActiveX? Is TestComplete running asynchronously (in parallel)? If so then how is the data getting back to TestStand?
So here are some options:
1. You can use the While Step type. It's in the Flow Control folder in your Step Types pallette. Look in your examples under UsingFlowControlSteps.seq in the SequenceFlow
2. You can loop on a step and have the termination for the loop be (return value == 30). Look in the Step Properties under Looping. Also in the TestStand help
3. You could do Post Actions based on a condition and have it jump to another step. Read about it in the TestStand Reference Manual.
4. You could use a GoTo step. I don't really recommend this one. It makes code hard to maintain. Also an example in SequenceFlow called gotobeep.seq.
Hopefully this gets you thinking. Let me know if you have specific questions about any of these methods.
07-01-2011 05:45 PM
Thanks Jigg. This worked!. I used the statement Parameters.Result =="32" in a IF statement to evaluate the return value from TC.
However, now I need to send back another value from this called sequence file to the calling sequence step within TestStand. How can I do that?
Do I need to create new parameter or locals in the tab of calling sequence step? Everything is empty now.
Thanks
07-01-2011 05:57 PM
Parameters are the best way to pass data to and from sub sequences.
However, is the sequence running in a new thread? Then you may want to use a queue or notifier.
07-07-2011 02:15 PM
Jigg,
No, the program is not running a new thread. It's just a single sequential thread. It calls other sequential files and that's it.
I think I'm having some luck using the StationGlobal. It appears to be working (e.g setting the StationGlobal in one sequence file automatically updates the Stationglobal in another sequence file, kind of like passing the value by reference)
Thanks!
03-31-2016 07:24 AM
Hello,
I tried to start a script using TestStand and TestComplete ActiveX but without success.
I have TestStand 2013 and TestComplete 11.
May you please send me the TestStand Sequence that starts your TestComplete script and retrieve the data ?
Best regards,
Armindo PINTO
04-20-2016 09:05 AM
04-21-2016 08:27 AM
I don't see attached.