NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

What TypeLibrary data type does the TestStand dll adapter treat as a Boolean?

What datatype shall I put in my idl to create a TypeLibrary that the TestStand dll adapter treats as a Boolean?
0 Kudos
Message 1 of 6
(4,047 Views)
Perni -
The type should be "VARIANT_BOOL".
Scott Richardson
https://testeract.com
0 Kudos
Message 2 of 6
(4,032 Views)
Thank you verry much for your reponse, though it does not seem to help.

I have the following entry in my idl.

[ entry("Res_RunHookRes_RunHook"), helpstring("Run all hooks in the hook_list")]
RES_API Res_RunHook
(
[in] int dut_index,
[in] LPCSTR hook_list,
[in] VARIANT_BOOL wait
);

And I get the signed 16 bit integer representation, just as in TestStand 2.0.1.
Though, In TestStand 3.1, there is an "Boolean" category (See attachment)
How can I get that representation in the TestStand dll adapter.

Message Edited by perni on 03-12-2005 12:32 AM

Message Edited by perni on 03-12-2005 12:33 AM

Download All
0 Kudos
Message 3 of 6
(4,024 Views)
Perni -
What compiler are you using to create your DLL, CVI or MSVC?
If MSVC, are your functions C or C++?
If MSVC, are you using a .DEF file
Scott Richardson
https://testeract.com
0 Kudos
Message 4 of 6
(4,000 Views)
Perni -
I looked at this further. You are correct in that the type library type of either VARIANT_BOOL or Boolean are interpreted as short or int16 by the DLL Adapter. The Boolean category in the ring control for the adapter was added specifically for a C++ function built by MSVC. This support was added in the 3.x timeframe. So if you have a MSVC DLL with a "bool" data type, it would be properly discovered. I suspect that we did not look back at the issue of importing a Boolean in a type library. I will report this to see if this can be fixed in the future. In the mean time you will have to manually change the item to Boolean for each new step that you configure.
Scott Richardson
https://testeract.com
0 Kudos
Message 5 of 6
(3,987 Views)

Has there been an update to address this issue yet?

0 Kudos
Message 6 of 6
(2,924 Views)