Clear Filters
Clear Filters

Dll is not a valid Win32

37 views (last 30 days)
Max-Henri
Max-Henri on 28 Feb 2023
Answered: Animesh on 10 Mar 2023
Hi all,
I am running a 64bit matlab and I want to loadlibrary of a dll 64bit with matlab function (sim_proto.m).
loadlibrary('sim_win64',@sim_proto);
Matlab is giving me the following error
Error in loadlibrary
Caused by:
Error using
C:\simENMReplay_win64.dll is not a valid Win32 application.
I don't understand the error knowing that my matlab and my dll is 64bit. Can someone help me please ?
Thank you,
Regards,

Answers (1)

Animesh
Animesh on 10 Mar 2023
Hello,
The error message "is not a valid Win32 application" error usually means that you are attempting to load a 32-bit DLL using 64-bit MATLAB. It is not possible to load a 32-bit DLL file in 64-bit executables.
I tried to load the DLL file in a 32-bit MATLAB and still got an error. The DLL file you provided is most probably corrupt.

Categories

Find more on Startup and Shutdown in Help Center and File Exchange

Products


Release

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!