Integrate Matlab R2015b with C# MVC 5

I'm building an Matlab application that needs to integrate with C# MVC. This example provides one way to integrate .NET with MATLAB.
The Matlab application uses an API that currently supports only 32 bit-R2015b (R2016 doesn't support 32-bit architecture).
This link says that R2015b supports only .NET 4.0. Is there any plugin/library that I can install so that Matlab R2015b supports .NET 4.5? Are there any other ways to integrate matlab application with C#?

Answers (1)

You will need to build it with .NET 4.0 but you might be able to run it on a system with .NET 4.5. See http://www.mathworks.com/matlabcentral/answers/293615-mcr_r2013a_win64-net-framework-4-5-2

4 Comments

Hi Walter, It still crashes at the point of initialization of the MATLAB object. At this line ( obj = new MLTestClass(); )
Turning off the JIT did not make a difference.
Are you building on a system that has .NET 4.0 installed? Is your test that crashes on a system that has .NET 4.0 installed or on a different system that has only .NET 4.5 installed?
I'm building and running on the same system that has Visual Studio 2015(32-bit) with .NET 4.5. The MATLAB version as I said is R2015b(32-bit)
You will need to build it on a system with .NET 4.0. Once built with 4.0 you might possibly be able to run it on a system that has only .NET 4.5 installed, but we are not certain about that. You will not be able to build it on a system that does not have .NET 4.0

Sign in to comment.

Categories

Asked:

on 14 Jul 2016

Commented:

on 17 Jul 2016

Community Treasure Hunt

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

Start Hunting!