Why do I get an error "undefined function matlabrc" after several successful executions of my standalone application?

18 views (last 30 days)
I have compiled my application and it runs fine on the target machine for some period of time and then suddenly it stops working with the following error:
"undefined function matlabrc"
There is no pattern or consistency in the number of executions or the period of time that the application runs before it stops working.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 1 Dec 2009
This behavior can occur if the MCR cache becomes corrupted in between two executions. To resolve this issue, you would need to delete the directory to which the CTF is extracted, so that it would be re-extracted with the next run of the standalone application. This directory can be obtained by typing the following at the MATLAB Command line:
mcrcachedir
In version MATLAB 7.6 (R2008a), this defaults to a sub-directory of your local settings directory on a Windows platform. In versions MATLAB 7.7 (R2008b) and higher this defaults to the temporary directory as specified by the TEMP environment variable. These directories may be modified when running automatic updates or running backups as configured by your system administrator.
Also, to avoid these sort of directory corruptions, make sure that no other process can reach the directory to which the CTF gets extracted.

More Answers (0)

Categories

Find more on Environment and Settings in Help Center and File Exchange

Products


Release

R2008b

Community Treasure Hunt

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

Start Hunting!