MATLAB: Package Standalone Application with MCR Libraries

app designerapplicationMATLABmcrmcrinstallerstandalone

Hello,
I am trying to create a standalone application with "Runtime included in package" (Since we do not have administration rights in the computers of my office, I guess that this option will be much more efficent for my colleagues). However I am having problems when selecting it:
I have explored seceral simmilar topics like this:
or
But I haven't figured it out yet!. The MCR libraries that I have downloaded are: MATLAB_Runtime_R2019b_Update_7_win64.zip
My version of matlab is: 9.7.0.1190202 (R2019b) (Hence, I guess that the update 7 is te correct one)
The command
compiler.runtime.download
does not work to me due to administration right limitations.
When I tried the option Runtime Included In Package\ download from web, the next error message appears in the log:
A connection could not be established to download the Runtime Installer. Download the runtime from https://www.mathworks.com/products/compiler/mcr.html and update the runtime location in Compiler Settings.

Best Answer

Hi!
I have contacted the Technical Support Center and this is the solution for this issue:
The error you are encountering is likely the result of not installing the correct version of MATLAB Compiler Runtime. I would suggest obtaining a new MATLAB Runtime Installer by following one of the two steps below:
1. Run the following command and note the download location:
>> compiler.runtime.download
​​​​​​​2. Run the following command to obtain a URL which you can open in a web browser to download the correct version:
>> com.mathworks.toolbox.compiler.MatlabRuntimeUtils.getMCRInstallerDownloadURL()
​​​​​​​I believe that if you re-download the MATLAB Runtime Installer and specify the new location, this should resolve your issue