NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand testing the return value from dll

Hi,

 

As my subject states: I want to test the return value from dll. I would know how to do this in C but this TestStand code is nothing like that.

 

Here's my logic:

 

Calling my dll

 

if ( dll returns -2 )

abort this sequance file

else

continue

 

Thanks in advance

 

Michael B.

0 Kudos
Message 1 of 2
(3,184 Views)

Have you done a Teststand tutorial already? That helps a lot I think.

I assume you have an C/C++ dll?

Insert step->Tests->Pass/fail test
Select Adapter: C/C++ DLL
 
Module:module --> browse to dll
select the function (your inputs/outputs should show up now...)
You can bind a variable to the output

Data Source (your pass condition)-->Step.Result or your variable  (press the f(x) to browse)
opt1: return variable != -2
opt2: return variable == -2

Properties->Post Actions->
opt1: On Fail: Terminate Execution (more neat one, it terminates on false)
opt2: On Pass: Terminate Execution

0 Kudos
Message 2 of 2
(3,171 Views)