From 08:00 PM CDT Friday, August 12 - 01:00 PM CDT Saturday, August 13, ni.com will be undergoing system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Caling external Dll problem

Hi to all,
I am calling a dll in TestStand. Actually the dll contains 462 functions. But in TestStand it shows only 4 functions (which define as static). How could I access other functions?
 
Regards.
0 Kudos
Message 1 of 4
(2,219 Views)
Hi,
 
When calling functions and class methods in a DLL from TestStand, there are a number of requirements for you to access these functions.  One of these requirements is that the methods must be static and public.  So it is expected that the only functions you currently have access to are the ones that were declared as static.  You can find out about all the requirements for accessing methods and functions from a DLL in the section "Exporting Class Methods and Functions in Visual Studio" found in the TestStand Help.
 
Take a look at this help entry and let me know if you have any more questions.
 
Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 2 of 4
(2,198 Views)

Hi Caroline,

Thank you for the reply. 

The DLL, I am try to access has a few functions defined as Public and Static both. But some are not defined as static but they are defined as public.  As functions defined by as Public and Static are comming in the function list. But the others are not comming. Is there any way to get this functions (Not defined as static) in the function list or other way to access it?

 

thanks,

regards,

vishal.

0 Kudos
Message 3 of 4
(2,186 Views)

Vishal -
We are assuming that you are attempting to call C++ methods exposed by a DLL. TestStand can call static methods because the methods do not need an object to be created before calling them.  TestStand has no way of creating a C++ object, so it cannot list the public methods on the class. If you have access to the DLL source, you could expose new static methods on the class, or you must wrap this DLL in another DLL that exposes C functions or static C++ functions that TestStand can call.

Scott Richardson
National Instruments
0 Kudos
Message 4 of 4
(2,168 Views)