My sequence file have 2 FileGlobals variales in the Sequence Editor. When I modified one variable, I wish the another variable can be changed with the first variable automatically. Is there a convenient method to do that?
I'm pretty sure this isn't available. I've never seen anything like this in any language, let alone TestStand.
What is your goal with this? Maybe there is a better way to accomplish what you desire.
Thanks for your reply!
It is useful in the following example,
struct BBBB ss; // express with Container variale in TestStand
short dd; // express with Number variable in TestStand
In TestStand Editor, I define 2 FileGlobal Variable, one is dd with number type, the other is ss with container type. Variable ss and Variable dd have the same size, child item (a,b,c,d) of ss has the intuitive meaning, but when it is about to read or write data (stored in dd), they must be a whole.
Sometimes a specifed child of ss is midified, the value of dd must be modified synchronously.
Maybe three methods can resolve this question,
But I don't know actual solution.
Do you need it to happen when they update the variable? Or does it just need to occur before they execute? If that is the case you can do it in the ProcessSetup callback.
SequenceFileLoad is not a good choice because then you would need to call SequenceFile.Save(). This requires the development license so if you ever move to a deployment license you would be hosed.
I don't know how a UI Message would help you here.
I'm assuming you want to perform a C type union between a shortint and a structure of integers?
I'd try using a seperate thread to monitor and update the FileGlobals, see the attached example.