MATLAB: LoadLibrary with a dll the references other dlls

directorydllloadlibraryMATLABMATLAB Compiler

I am using Matlab 7.10 and in my .m file use loadlibrary to connect to an external device. (call this a.dll) I can call and use functionality within my a.dll fine.
I have trouble using my a.dll loaded when it loads in other libraries(call this b.dll and c.dll) within a.dll It cannot find them.
I have placed the other dlls(b.dll & c.dll) that my library(a.dll) references in the same matlab directory (with the m files)
I thought I might be able to use loadlibrary to get them into scope, but I do not have .h files for these other dlls (b.dll & c.dll) and that seems to be required, nor do I want to write out a prototype for each of these nested dlls(there are more then just b and c)
If I use 'pwd' my current directory returns my matlab directory, is there somewhere else these dlls(b.dll, c.dll) should be placed?
Thank you

Best Answer

Hi,
a.dll can only find b.dll and c.dll, if b.dll and c.dll are on the system path (i.e., the path you get when you do
getenv('PATH')
Put c.dll to a folder on the system path (like c:\windows\system32) or add the folder to the system path.
Titus
Related Question