MATLAB: Do I get a Command line option syntax error when installing MATLAB

MATLAB

When I install MATLAB I get an error from VCRuntime:
Command line option syntax error. Type Command /? for Help.
This may be followed by another error:
Error calling main.
or
Exception calling main.
Then the installation quits. How do I install MATLAB?

Best Answer

MATLAB relies on a Microsoft Visual C++ Redistributable to run properly. When MATLAB installs, it will also install the correct version of this Microsoft software. This error message indicates that installation failed.
This will happen if the directory the installation files were downloaded to contains a space. To work around the issue, move this folder to location without a space in the path. For example, C:\MLdownload. Note that if this is a folder on your Desktop or Temp folder and your Windows username contains a space, the path to that folder will also contain a space.
If moving the folder isn't possible, you can also work around the issue by running the installer for the Microsoft Visual C++ Redistributable manually. The installer can be found on the DVD or in the downloaded files from the website.
$MEDIA\bin\win32\vcredist_x86.exe
($MEDIA\bin\win64\vcredist_x64.exe for 64 bit Windows)
Where $MEDIA is the folder you downloaded the MATLAB installation files to or the location of the DVD you are installing from.
Afterwards you should be able to install MATLAB without any issues.