- First, make sure MATLAB is registered as a COM Automation server.
- It can be registered by executing 'regmatlabserver' in the MATLAB Command Window.
- Add a reference to the MATLAB Application COM object in your C# project. Please follow the below steps for accomplishing this in Visual Studio.
- From the Project menu, select Add Reference.
- Select the COM tab in the Add Reference dialog box.
- Select the MATLAB application.
Why am I getting the error "The type or namespace 'MLApp' could not be found" when building C# application using MATLAB?
3 views (last 30 days)
Show older comments
MathWorks Support Team
on 27 Sep 2019
Edited: MathWorks Support Team
on 30 Dec 2020
I am trying to connect to the MATLAB Application COM interface from my C# project and when I try to build it I get the error "The type or namespace 'MLApp' could not be found". How do I add this missing reference?
Accepted Answer
MathWorks Support Team
on 30 Dec 2020
To resolve this, you will need to add MATLAB Application as a COM reference in your C# project.
0 Comments
More Answers (0)
See Also
Categories
Find more on MATLAB Compiler SDK in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!