I have a simple MATLAB code which uses the Icons provided by MATLAB. The icons provided by MATLAB are located at following location in my MATLAB:
<matlabroot>\toolbox\matlab\icons
Hence I used the same path and wrote the following code:
function test imread([matlabroot,'\toolbox\matlab\icons\pin_icon.gif']);end
I observed that my code worked fine in base MATLAB. However, when I created a standalone application from the same code and I tried to run it on deployment machine, the standalone application failed with following error message:
ERROR: Error using imread File "C:\Program Files\MATLAB\MATLAB Runtime\v901\toolbox\matlab\icons\pin_icon.gif" does not exist. Error in test12 (line 2) MATLAB:imagesci:imread:fileDoesNotExist
On further investigation I noticed that the "icons" folder was missing at following location "<matlabroot>\toolbox\matlab\" in MATLAB Compiler Runtime.
Why does this application fail and why isn't there "icons" folder at "<matlabroot>\toolbox\matlab\" in MATLAB Compiler Runtime?
Best Answer