Hi guys,
I'm having problem using the "TS_ExecutionGetStates" function on my LabWindows/CVI application.
The returned parameter value "TerminateState" is working done when I click in the STOP button of TestStand, but the "RunState" parameter always have the value of "TS_ExecRunState_Running", not changing to "TS_ExecRunState_Paused" state when I click in the PAUSE button of TestStand.
How can I know that operator paused the test?
Follow my code:
|
TSObj_Execution ExcObj; enum TSEnum_ExecutionRunStates RunState; enum TSEnum_ExecutionTerminationStates TerminateState; char *Msg = " "; TS_SeqContextGetExecution (seqContext, NULL, &ExcObj); EnableTaskSwitching(); do { TS_ExecutionGetStates (ExcObj, NULL, &RunState, &TerminateState); sprintf(Msg, "RunState: %d, TerminateState: %d\0", RunState, TerminateState); MessagePopup("Title", Msg); Delay(1);
}while ((RunState == TS_ExecRunState_Running) && (TerminateState == TS_ExecTermState_Normal));
|
Thanks.