opening matlab lab from command line uses different java version than from shortcut

I went to use matlab -jdb and my application failed to run (could not find the java class). When I checked the java version it was wrong. The version displayed the version Matlab was shipped with. I checked when ever I open Matlab from the start menu or desktop short cut I get the proper version. This version of java was set via environment variable MATLAB_JAVA. When I open matlab via the command prompt I get the installed version not the version listed in the MATLAB_JAVA enviroment variable. How can I run matlab -jdb and get the correct version of java?

类别

帮助中心File Exchange 中查找有关 Startup and Shutdown 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by