08-23-2022 06:50 AM
Hi,
I was just playing around trying to access a TestStand queue in an expression, basically trying to recreate the following LabVIEW Code.
So far I have failed to cast the IUnknown Refences returned by GetSyncManager to ISyncManager....
there seems to be no AsISyncManager cast or alike.
Anyone's got some advice on how to perform this cast within an expression?
Cheers
Oli
Solved! Go to Solution.
08-26-2022 05:25 AM
Hello,
I just made the same observation. It is like if, in TestStand Sequence Editor, the class ISyncManager is unknown. And that's the same from ActiveX Adapter Steps, I didn't find to specify the class SyncManager.
This said, if you consider that TestStand, in the sequence editor context, will handle for us the SyncManager, we don't need to be able to manipulate it from an Expression: you can manipulate Queues, Notifiers, and other synchronization tools without even knowing that the SyncManager is involved nor exists.
The only case I had to access the SyncManager was to send a notifier from a LabVIEW application to the TS engine, where the Notifier was initialized by TestStand. In that case (from LabVIEW), it make sense to be able to access to the SyncManager, to allow an application (LabVIEW) to 'use' synchronization tools, from the 'outside' of TestStand.
Why do you try to access a queue in an Expression ?
08-26-2022 09:06 AM
Expressions only expose what's in the NI TestStand API. The SynchManager is part of the NI TestStand Synchronization. So you have to use an ActiveX step as Mathieu pointed out.
Hope this helps,
09-05-2022 01:13 AM
Mathieu, jigg,
thanks for your help!
in fact I wanted to avoid using an ActiveX step and use an expression instead. I am tinkering with some custom step types, where this would've come in handy.
Yet, it seems, I'll use ActiveX steps instead.
Cheers
Oli