03-05-2018 09:33 AM
Hello
I am trying to call a third party DLL from LabVIEW and finding this issue:
Call library function note .... Library not found or failed to load
_______
The library specified for this node cannot be found or cannot be loaded. Right-click the Call Library Function node and select Configure, then choose the correct library name or path.
I have checked with dumpbin that:
I've tried with the wizard including the header file, and the directory containing the lib file, as well as the preprocessors directives that are usually included int he C examples.
This is a specific Modbus Client implementation with some "extra steps" so to speak, so I would like to get it to work through the dll rather than use the standard NI Modbus library.
I know that the LabVIEW error message isn't very specific, so if anyone has any insight of what could be going wrong here or how I can further troubleshoot the issue, it would be most appreciated.
Thank you
03-05-2018 01:19 PM
Is it possible that this DLL has some other dependencies it can't find? Such as a runtime? I loaded it into Dependency Walker which exploded a bit but it seems like maybe something from Visual Studio?
03-06-2018 03:07 AM - edited 03-06-2018 03:08 AM
Your DLL has two dependencies that could be a problem.
1) MSVCR100.dll: This is the C runtime library from Visual Studio 2010. Make sure you download the redistributable package for the Visual C runtime library 2010 and install it on your system.
2) JVM.dll: This is the Java virtual machine runtime library. Your DLL apparently was generated from some Java code and that requires the Java runtime engine (of a compatible version) to be present on your system and accessible for the LabVIEW process.
It means you need to install the Java JRE and probably add the path to the directory where the JVM.dll file is installed (something like <Program Files (x86)>\Java\jre<version>\bin\client) to your PATH environment variable.
03-06-2018 07:37 AM
Thanks for the replies
1) Yes, the Visual C++ redist 2010 was installed already on the system. msvcr100.dll is in system32
2) That is correct. However, JRE was already installed, jvm.dll added to the path environment variable and displaying correctly with java -version on cmd
03-07-2018 05:09 PM - edited 03-07-2018 05:09 PM
@Pablo.Fernandez wrote:
Thanks for the replies
1) Yes, the Visual C++ redist 2010 was installed already on the system. msvcr100.dll is in system32
Do you use a 32 bit Windows system? Otherwise the right location for msvcr100.dll for 32 bit applications would be SysWOW64, meaning you need to install the 32 bit version of the MS Visual C runtime library.
03-13-2018 04:40 AM
Hi,
Yes, sorry for the late reply. I have a 64-bit machine but i have both the 32 bit and the 64 bit 2010 c++ redist installed, so they are both in system32 and in syswow64