Using 2018b javaclasspath.txt doesn't seem to get loaded during batch startup.
조회 수: 4 (최근 30일)
이전 댓글 표시
I am trying to run matlab 2018b in batch mode under windows using the task scheduler. The command options are:
-useStartupFolderPref -nosplash -minimize -r my_script_file
I have a javaclasspath.txt file in my startup folder. my_script_file works when matlab is launched by double clicking the icon. During the batch mode startup, the java class path does not include the contents of my javaclasspath.txt file - it does when matlab is started by double click.
Am I doing something wrong?
댓글 수: 0
채택된 답변
Andrew Stamps
2019년 4월 4일
Have you attempted putting your javaclasspath.txt file in your preferences directory instead of your startup directory? The preferences directory can be found by executing the following command:
prefdir
For more information, see the following: https://www.mathworks.com/help/matlab/matlab_external/static-path.html
추가 답변 (1개)
Yair Altman
2019년 2월 11일
I'm not sure why your javaclasspath.txt file doesn't load in batch mode. As workaround, you can programmatically load the necessary Java classes into the static Java classpath inside your script file, as described in https://undocumentedmatlab.com/blog/static-java-classpath-hacks
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Startup and Shutdown에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!