Failed to load a .NET assembly
11 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
When I try to load a .NET assembly by typing:
asm = NET.addAssembly('fullPath');
I get the following error: "Could not load file or assembly 'file:///fullPath' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded. Source: mscorlib HelpLink:"
I've Matlab R2010a and the assembly is targeted for .NET framework 4.0.
0 comentarios
Respuestas (1)
Kaustubha Govind
el 1 de Ag. de 2011
What version of MATLAB did you use to build your .NET assembly? The latest version (R2011a) supports .NET Framework 4.0: http://www.mathworks.com/products/netbuilder/requirements.html, but I know that older releases used older .NET versions. You might need to build with a newer version to load your assembly with 4.0.
2 comentarios
Kaustubha Govind
el 2 de Ag. de 2011
Oops. Apologies! I misunderstood your question.
The issue you are facing has been documented at http://www.mathworks.com/support/solutions/en/data/1-CNPYZV/index.html
So it looks like you will need to upgrade to R2011a to be able to use .NET 4.0 assemblies.
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!