matlab runtime mwarray assembly failed to be initialized after running my application for multiple days

30 views (last 30 days)
We have a C# application using matlab code compiled in a DLL. It always works, except when running the application for a long time, then close it and restart the application. The application can not load the matlab runtime at this point. It gives the following error:
Failed to start matlab runtime mwarray assembly failed to be initialized
We can only solve it by restarting the computer. Is there a way to prevent this from happening or resetting the matlab runtime without having to restart the pc?

Answers (1)

Pravarthana P
Pravarthana P on 2 Dec 2022
I understand that you are facing issue with C# application which is running for a long time.The following suggestions might help you:
1.The MCR cache might be corrupted, clear your MCR cahce. The following answer post contain steps to clear the cache:
2.Check whether you are using any of the following functions in your code. These functions are not supported for compilation and might create issues after compilation. Refer to the following documentation to identify the unsupported functions:

Products


Release

R2020b

Community Treasure Hunt

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

Start Hunting!