MATLAB: Do I get the error: “Failed to start the Desktop: Failure loading desktop class” on Mac OSX

MATLAB

When I start MATLAB on Mac OSX, it bounces in the dock and does not start. If I start MATLAB in the Xterm by running the MATLAB script, I get the following error:
Failed to start the Desktop: Failure loading desktop class

Best Answer

This error can occur if you are running an older version of Java on your machine. To verify what version of Java you have installed, open the Terminal application from /Applications/Utilities and run the following command:
java -version
If you do not see the 1.5 version, you can resolve this issue by downloading and installing the correct version from Apple's website. Once installed, MATLAB should start normally.