06-21-2018 10:47 AM
Hello Community,
I have two TestStand Sequences calling each other. Only the second sequence is known. The first one can have any name and be in any path.
The first sequence, let´s call her SeqA, calls a SubSequence, called Test, from the second sequence, I´ll go for SeqB. In the subsequence Test is a call to a SubSequence from the SeqA.
My problem is, that I´m unable to get a reference of SeqA to SeqB for the sequence call.
I already have the Sequence Context from SeqA. I would be very happy, if that would somehow be enough, to get the reference.
I just don´t want to pass two parameters, if not necessary.
Greetings Fred
Solved! Go to Solution.
06-21-2018 01:15 PM
RunState.Caller.SequenceFile.Path
06-21-2018 01:21 PM
If you have to use the sequence context then do something like this:
Parameters.MySeqCtxt.AsSequenceContext.SequenceFile
06-22-2018 02:23 AM - edited 06-22-2018 02:49 AM
Good monring jiggawax,
thank you very much for your answers. Both solutions work perfectly.
The "as solution" marked reply is the one I´ll use in my sequence.
I wish you a pleasant weekend.
Sincerely Fred
03-30-2020 07:51 AM
Hi,
I'm currently at an almost similar situation and don't see the (maybe obvious) solution:
I'd also like to pass a sequence as a reference to a called sequence. But in my case it is not the calling sequence I want to pass.
Lets say I have two sequences:
1. TestAInputs
2. TestBInputs
Now I have another Sequence "TestVariableInputs" to which I want to pass either TestAInputs or TestBInputs or others in the future.
At the moment I don't see how to generate or select the required parameter-type.
Kind Regards
David
03-31-2020 12:46 PM
@david_feo wrote:
Hi,
I'm currently at an almost similar situation and don't see the (maybe obvious) solution:
I'd also like to pass a sequence as a reference to a called sequence. But in my case it is not the calling sequence I want to pass.
Lets say I have two sequences:
1. TestAInputs2. TestBInputs
Now I have another Sequence "TestVariableInputs" to which I want to pass either TestAInputs or TestBInputs or others in the future.
At the moment I don't see how to generate or select the required parameter-type.
Kind Regards
David
Remember that a sequence context is completely different than a sequence. You can use an object reference to pass as a sequence. However, my guess is that's not what you need.
How are you getting references to the sequences? Are they executing? If so are they in the call stack?
04-01-2020 02:14 AM
Hi Jigg,
thank you for your reply.
Oh I was not clean enough. I just want to pass the reference to a sequence, in order to call them in the called sequence then.
In my stated Examle it would look like (as in C):
TestAInputs()
TestBInputs()
And
TestVariableInputs(sequence *pVariableFunc())
Then either call
TestVariableInputs(&TestAInputs)
{
*VariableFunc(); // which is TestAInputs() here
}
or call
TestVariableInputs(&TestBInputs)
{
*VariableFunc(); // which is TestBInputs() here
}
so maybe Passing a sequence as object reference would be fine, but how can I manage this?
Kind Regards
David
04-02-2020 08:47 AM
How are you getting references to the sequences? References to most anything in TestStand can be stored in Object Reference types.
04-02-2020 10:55 AM - edited 04-02-2020 10:59 AM
How about something like this: (see attached)
EDIT: I just noticed there was more history to this thread than I thought, so I might be repeating something or not addressing the latest.
04-03-2020 06:18 AM
Hi James,
thank you, that is exactly what I was looking for. Thank you very much!
Kind Regards
David