NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How can i determine if my dll is called by a edit step or runtime step?

Hello,

I'd like to determine in a CVI DLL, if it is called by a edit step or if it is a running sequence. Do you have any idea how to find this out?
0 Kudos
Message 1 of 2
(2,920 Views)
Thomas -
If TestStand calls a module from a substep (edit, pre, post, or custom), the sequence context will define at runtime the properties RunState.SubstepName and RunState.Substep. If you pass the context to the module, the module can use the TS API to determine if one of these properties exist. If you cannot pass the context to the module, but have a "boolean" parameter that indicates whether the a substep is calling it, you could use the expression 'PropertyExists("RunState.SubstepName")' for the parameter value.

If you have no way of getting the context to the DLL or pass a parameter, there is no way to tell.

Scott Richardson
Scott Richardson
https://testeract.com
Message 2 of 2
(2,920 Views)