From: kees de Kapper on
Hi All,

I'm trying to compile my Matlab m-file into an executable. After struggling with dll- inclusions it now works and the application starts-up.

However, calling the functions in the dll doesn't work. When calling these, the return value of these dll-functions is always 'error' (but it give no addition information why it returns and error-value). I do use a lot of pointers since the external functions requests those (but that is quite common for dll-functions), but that hasn't been a problem when running within Matlab.

I use the following mcc code:
mcc -ev -a C:\MyDLL.dll -R -logfile -R output.MyAPP_GUI_LOG ..\MyAPP_GUI.m

What could be the problem? What could be the solution?

Many thanks in advance!

kind regards,
Kees
From: kees de Kapper on
Luckely I've found the solution.

I had two versions of the runtime environment on my computer, however, the old versions was always used. This gave the weird behavior when running an app, which was compiled in 2009 using the 2007 MCRInstaller.

I've removed the 2007 MCRInstaller, and everything works fine.

Cheers,
Kees