Call Library Function Returns the Wrong Function Prototype and Function Parameters for DLLs

Updated Dec 20, 2017

Reported In

Software

  • LabVIEW Full
  • LabVIEW Base
  • LabVIEW Professional

Programming Language

  • LabVIEW G

Issue Details

When I use the Call Library Function Node with its built-in wizard to browse my available functions, the options listed are completely incorrect. It then defaults to a return type of void, and input parameter of void. When I open the Call Library Function Node properties, and search for my specific DLL to select my wanted Function name, I get the following error: 

Solution

This error is displayed becase the DLL does not recognize a Type Library (typelib, or LIB) file that was created for the DLL. The typelib file contains the list of public functions in the DLL, function prototypes, parameters, parameter types, etc.

You must use a DLL with an associated typelib file before the correct functions can be displayed.

Additional Information

Not all compilers will generate a LIB file by default when creating a DLL. The LabVIEW and LabWindows/CVI DLL builders do create them, however Microsoft Visual C++ does not, for example.

WAS THIS ARTICLE HELPFUL?

Not Helpful