NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Step result in SIngle Threaded Apartment?

Hi:

I'm making a subsequence call using a New Thread and Single Threaded Apartment options. This is required so that some Active X functionality will work in the DLL calls of the subsequence. However, if any step fails in the Single Threaded Apartment, I don't see the step result in the Teststand report. I can see the failed sequence (based on the Wait step which collects the result), but not the step. If I uncheck the Single Threaded Apartment option, I can see the failing step in the report.

Can anyone tell me how to fix this so I can get failing steps from a STA in the report?

Thanks,
Dave
0 Kudos
Message 1 of 4
(3,787 Views)

This behavior should be dependent on whether you launch a new thread, not whether the thread is STA. Assuming that this is the case, insert a Wait step right after your sequence call step, select Wait for Thread, and select your sequence call step.

The Wait step will wait for the thread you spawned and it will retrieve its results. In the report, it will look like the Wait step called the subsequence.

0 Kudos
Message 2 of 4
(3,777 Views)
I realize it should not behave like this, but it does.
I already have a Wait step to collect the results, and I'm using a New Thread call.
If I check the STA option, I don't get step results. If I uncheck it, I get step results.
Thoughts?
Thanks,
Dave

0 Kudos
Message 3 of 4
(3,775 Views)
False alarm.... I found the problem. The subsequence properties had 'Disable Result Recording For All Steps' checked. Unchecking this fixed the problem.

I went back to double-check just unchecking STA fixed the problem, but it didn't, as you suspected. I must have done something else differently when I checked this yesterday.

Anyways, it is working now - thanks for replying.

Cheers,
Dave
0 Kudos
Message 4 of 4
(3,769 Views)