How to update a GUI programmatically
Show older comments
I'd like to offer the user the opportunity to automatically update a GUI to the latest version. I can check for and download an updated installer if available. The main challenge is to exit the GUI after launching the installer so it can be overwritten. It would be nice to restart the GUI after installation too. The following code doesn't work, because system waits while the installer is running, so the installer can't overwrite the GUI because it's in use.
status = system('GUIInstaller'); %run the installer for the new version
if status==0
% if successfully executed, close application
closereq();
ImaginaryCommandToRestartTheApplication()
end
Is there a way of launching the installer and not waiting for it to complete?
I'm using the Matlab Compiler App to create the installer, so it's not hugely versatile.
Accepted Answer
More Answers (0)
Categories
Find more on Introduction to Installation and Licensing 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!