MATLAB: Do I get a ‘Please register MATLAB Software as a COM Server’ message in Excel after setting up the Excel Spreadsheet Link Add-In

comexcellinkMATLABserverspreadsheetSpreadsheet Link

When trying to start MATLAB through Excel, I keep getting the error message:
 
MATLAB Startup Error
Unable to start MATLAB. Please register MATLAB Software as a COM Server.
I have already set up the Excel Spreadsheet Link Add-In. Why do I keep receiving this error message? 

Best Answer

If the MATLAB version is set incorrectly, MATLAB does not start and displays this error: Unable to start MATLAB. Please register MATLAB Software as a COM Server. Set the MATLAB version using <https://www.mathworks.com/help/exlink/mlprogramid.html MLProgramId>.
Ensure that the correct MATLAB version appears in the Preferences dialog box before starting MATLAB. For details, see <https://www.mathworks.com/help/exlink/setting-spreadsheet-link-preferences.html Setting Spreadsheet Link Preferences>.
If MATLAB is installed on your computer and setting the MATLAB version does not work, use the last registered version to start MATLAB. To specify the last registered version of MATLAB:
  1. Shut down all MATLAB and Excel® sessions.
  2. Open a command prompt window, and using cd, change to the bin\win64 subfolder of the MATLAB installation folder.
  3. Enter the command:
.\matlab /regserver