Why do I get the error "Undefined function or variable 'onCleanup'"?
14 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi everybody. Opening programs I get this error:
Undefined function or variable 'onCleanup'.
Error in getnicedialoglocation (line 21)
c = onCleanup(@() close(convertData.hFig));
Error in msgbox (line 324)
DefFigPos = getnicedialoglocation(DefFigPos, get(figureHandle,'Units'));
Error in errordlg (line 47)
handle = msgbox(ErrorStringCell,DlgName,'error',Replace);
Error in uiopen (line 194)
errordlg(err);
What can I do to solve the problem and start using Matlab again?
0 Kommentare
Antworten (2)
ES
am 30 Mai 2017
Something is wrong with your path.
onCleanUp resides here. It should be visible on startup.
{MATLAB Installation Directory}\toolbox\matlab\general\onCleanup.m
Try
which onCleanup
restoredefaultpath
commands
0 Kommentare
Jan
am 30 Mai 2017
The first point to start is asking the docs about this function. In the current version found on the MathWorks pages (and found by Google):
There it is mentioned, that the function was "Introduced in R2008a". Do you run an older version? Then it would be useful, if you mention this.
0 Kommentare
Siehe auch
Kategorien
Mehr zu Startup and Shutdown finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!