Filter löschen
Filter löschen

Problem with accessing C# dll files

3 Ansichten (letzte 30 Tage)
MaheKK
MaheKK am 4 Nov. 2014
Kommentiert: MaheKK am 4 Nov. 2014
->I have a C# Dll file named ACE.dll,copied dll file to Matlab working directory(current folder),and i am using loadlibrary('ACE.dll'); syntax for loading libraries,there are no .h header file so i made my syntax loadlibrary('ACE.dll'); but i am getting an error stating
"Error using loadlibrary (line 254) A 'Selected' compiler was not found. You may need to run mex -setup.
Error in ImportDll (line 3) loadlibrary(fullpathToDll);"
->After running mex -setup, i have said 'y' to locate installed compilers,but got an error
"No supported SDK or compiler was found on this computer. For a list of supported compilers, see http://www.mathworks.com/support/compilers/R2012b/win64.html
Error using mex (line 206) Unable to complete successfully."
->Both Dll and Matlab are with 64 bit only, I have installed VS Express 2013 for desktop. checked SDK version and having v7.1A and above until v8.1A.
What could be the reason? how can i access dll files? please help.

Akzeptierte Antwort

Titus Edelhofer
Titus Edelhofer am 4 Nov. 2014
Hi,
if you have a C# dll I guess it's not a usual Windows dll but a .NET assembly? In this case you would need to use
NET.addAssembly
instead of loadlibrary to import the dll to MATLAB.
Titus
  1 Kommentar
MaheKK
MaheKK am 4 Nov. 2014
Hi Titus,
Thanks for your information and time, That absolutely works fine :)
Mahesh.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Troubleshooting in MATLAB Compiler SDK finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by