Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to use a dll created with Matlab with Delphi?

Status
Not open for further replies.

blunt80fi

Electrical
Jun 23, 2004
6
0
0
FI
Hello everyone,

Has anyone used dll's made with Matlab (m-files compiled with mcc) in programs made with delphi? I know how to load the dll, and I know what the functions are called in the dll (they are listed in the .exp-file). But I can't make it work, Delphi gives me error: Access violation in module 'libmattlb.dll'. Does someone know why this happens? I don't have any input parameters in the main function, so it can't be because of different data types? Do I need to call the initialize-function, that is in the (dll-name).c, and also in the .exp-file? I tried also that, and then the delphi-program froze. I have tried to find answers on the internet, but all I find are the same questions I have, not the answers..

The dll is compiled with Matlab's compiler (lcc), version 3.

Thank you all in forehand.
 
Replies continue below

Recommended for you

i have the same problem, i think the solution is in mxcreate of matlab, i'm not sure but i think the input paramaters have incorrect type.
 
Status
Not open for further replies.
Back
Top