I've developed a JNI application in MS Visual Studio that calls Java methods from within a C++ file. All necessary files, such as jvm.lib and jvm.dll, have been included in the "Debbuging->Environment", "Linker->Input->Additional Dependencies" and Linker->General->Additional Library Directories configuration properties. The application runs fine inside Visual Studio, but when running the .exe file directly, it complains that the jvm.dll is missing. So I've copied the file from C:\Program Files\Java\jdk1.6.0_45\jre\bin\server to my VS project where the executable resides, but then I receive the error The application was unable to start correctly (0x000007b). How can I reference third party libraries in the .exe file? I preferably want to export environment paths and dependencies during the VS build process.
Regards,
Chris
Windows 7 64bit
Java JDK 1.6.45 64bit
MS Visual Studio 2012