11-02-2011 10:12 AM
Hi there. I need to edit a sequence file automatically with a LabVIEW program. We have a program the is successful in editing and saving a sequence file automatically which goes in and does a few things. However I also need to be able to go in and change a setting in Run Options for the top level SequenceCall steps in Main of MainSequence. I want to be able to change the Sequence Call Trace Setting for the steps from Disable Tracing in Sequence to Enable Tracing in Sequence. However I do not seem to be able to find this in the API call chin anywhere. At this point I am certain that it IS in there somewhere, but probably hidden under an option mask for something. Anyone know where I might find it?
This is NOT something I want to do at execution time. This is something I want to do by launching TestStand in edit mode from LabVIEW to automatically edit and save a new version of the sequence file.
Thanks!
Greg
Solved! Go to Solution.
11-02-2011 10:31 AM - edited 11-02-2011 10:34 AM
Use
RunState.Execution.TracingDisabled =True
In the Pre-Expression of the SequenceCall Step
and use
RunState.Execution.TracingDisabled =False
In the Post-Expression.
(If you are actually inserting steps into a sequence then you probably can setup the Adapter for the SequenceCall Trace Setting as you can manually)
11-02-2011 10:36 AM
SequenceCallModule.TraceSetting
Use the following constants with this data type:
Controls enabling and disabling tracing for calls to the subsequence.
This property corresponds to the Sequence Call Trace Setting control on the Run Options tab of the Step Properties dialog box.
11-02-2011 10:42 AM - edited 11-02-2011 10:42 AM
Edit: OOPS Didn't see that Ray had posted.
You can look in the TS help for each of these but in TS it would be:
Step.Module.AsSequenceCallModule.TraceSetting = 3 to disable.
I'm assuming in LabVIEW you would already have a handle to the Step however you are doing it in your current program.
11-02-2011 11:10 AM
Fantastic guys! Thanks agian!
11-02-2011 11:29 AM
Ok, perhaps I jumped the gun on my previous reply.
I just am not seeing SequenceCallModule as an available option under Step.Module. It is not listed under either the available properities or methods for Module.
I am woring on a reference to the stop from
IApplicationMgr.IEngine.GetSequenceFileEx.GetSequence.Sequence.GetStep
The available options I have for Module are:
Properities:
Adaptor
CanCreateCode
CanEditCode
IsPrototypeIncompatable
Step
UnmappedArgumentValues
Methods:
AsProperityObject
CreateCode
EditCode
GetDescription
Load
LoadPrototype
Specify
Unload
Thanks.
11-02-2011 12:25 PM - edited 11-02-2011 12:26 PM
Not sure if this will work. I'm kinda bummed the To More Specific Class function wouldn't work.
The Automation Refnum going into the top of the TypeCast is using the NI TestStand Adapter API 4.1.1 Version 1.0 as the type library and SequenceCallModule as the Object.
11-02-2011 12:30 PM
I'll try that right now and let you know. Thanks.
Greg
01-29-2013 03:33 AM
Hi,
The TypeCast doesn't run (-1073741819 error...). I use Variant to Data.vi instead
Regards
Xa