Environment:
64-bit Windows 10 version 2004 PC. 64-bit QB64 is installed, and a dynamic library named NmxDLLx64.DLL is added, which as its name indicates is 64-bit, in the same folder as the executable.
A program is created that uses the library without problem, even if it is copied to another folder
Library declaration
DECLARE DYNAMIC LIBRARY ". \ NmxDLLx64"
Laptop with Windows 10 version 1909 64-bit. Do not have QB64 installed.
Tests:
1) Copy program and DLL to laptop and run. Result: Cannot find the DLL (popup with message: 'Cannot find dynamic library file'.
2) Install QB64 on laptop. Copy the source of the program and compile it. Then the program works correctly.
3) Copy the executable again from the PC and run. The message box not found message appears again.
4) Create on the PC a path equal to the destination of the laptop where I want to install the application and its DLL. Compile it there. Copy it to the laptop and now it works.
5) One last test: Rename the folder where the executable and the DLL are located and it stops working
Conclusion:
The load address of the DLL is resolved in the compilation and linking process, from unit level.
Therefore, to deploy the application with its DLL, it must be copied to the same address relative to the computer that it was occupying when it was compiled.
¿There is another option?