02-01-2013 09:36 AM
Hello to everyone,
I am using TestStand 2010 SP1 and Visual C# 2008.
In C# I use the TestStand API (NationalInstruments.TestStand.Interop.API).
I have a step in TestStand where I pass all the context to the C# code (NationalInstruments.TestStand.Interop.API.SequenceContext MyContext)
I know how to access to the StationGlobals, Locals, ... through these methods: MyContext.StationGlobals.GetValBoolean("BoolExample", 0);
My problem is:
For example, in TestStand I can access to a variable (that is a step of a subsequence) called RunState.SequenceFile.Data.Seq[0].Main.[0]
but I don't know how access to this part of the RunState... and also others...
Thanks to all of you.
02-01-2013 04:02 PM - edited 02-01-2013 04:04 PM
Either:
myStep = MyContext.SequenceFile.GetSequence(0).GetStep(0, StepGroup_Main);
or
myStep = MyContext.AsPropertyObject().GetPropertyObject("RunState.SequenceFile.Data.Seq[0].Main.[0]", 0) as NationalInstruments.TestStand.Interop.API.Step;
Hope this helps,
-Doug