issue opening old apps in appdesigner
30 views (last 30 days)
Show older comments
I have an app that I believe is from MATLAB 2020b. When I try to open it in appdesigner in MATLAB 2023 or 2024, I am getting the following error:
Error using matlab.ui.Figure/set
Functionality not supported with figures created
with the uifigure function.
Error in addToolbarExplorationButtons
It is not clear to me which line is throwing this error. Is there an "update" program that can be run to fix this? If I open the code in an older version of MATLAB appdesigner, such that I can edit the code, is there a function call that I can change that will fix this?
Here's the set function (I think), although it is unclear why this is an error. I am pretty sure I can make the same call in newer versions of MATLAB without an issue.
function createComponents(app)
% Create figure and hide until all components are created
app.figure = uifigure('Visible', 'off');
app.figure.Position = [100 100 598 624];
app.figure.Name = 'MATLAB App';
where the app.figure is set as follows:
properties (Access = public)
figure matlab.ui.Figure
which I believe is what is causing the set call.
Oops, update ....
It seems that the appModel.mat file, which is in the mlapp has the figure creatFcn set, and basically calls: addToolbarExplorationButtons
It does not seem like the createFcn is exposed in the appdesigner (if I wanted to edit in an old MATLAB version). I also tried unzipping, editing appModel.mat my loading it into old MATLAB, overriding the creatFcn, and then saving to disk, rezipping the directory, and then changing the extension back to mlapp. However, when I do this I get that MATLAB is unable to open the app in appdesigner.
How do I "update" my app so that I can edit in newer versions of MATLAB?
2 Comments
Image Analyst
on 14 Dec 2025 at 0:29
Edited: Image Analyst
on 14 Dec 2025 at 0:31
I always think of .mat files as basically data files where you store variables, not as executable code that actually runs code and calls functions. Can you explain exactly how your mat file is actually calling the functions creatFcn(), set(), and addToolbarExplorationButtons()? Does that happen automatically somehow when you call load('appModel.mat')???
If you attach your .mat file and your .mlapp file, we can run it and possibly fix it.
You said you can run it in newer versions so why do you want to run it an old version from 2023 or 2024?
Answers (1)
dpb
on 13 Dec 2025 at 15:07
Moved: dpb
on 13 Dec 2025 at 16:11
I think you need to submit an official support request to Mathworks because, as your later posting notes, the internal functions are protected by AppDesigner and you can't mung on them outside it and be able to then open them again in the environment.
AppDesigner is supposed to be able to open any prior app; the only transition tool is the one for prior GUIDE-based apps that isn't applicable here.
2 Comments
Jim Hokanson
on 14 Dec 2025 at 4:45
Edited: Jim Hokanson
on 14 Dec 2025 at 14:55
dpb
on 14 Dec 2025 at 21:46
Yeah, anytime you do make any customizations, it's easy to forget having done so...
See Also
Categories
Find more on Startup and Shutdown 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!