Java Program crashing when launch from Matlab 2019a
Afficher commentaires plus anciens
I have a java program (.jar file) that i wish to run from Matlab 2019a.
As far as launching it goes it goes seemingly smoothly, When i click the button to launch it, it takes about 5-7 seconds and then launches fine.
From there i can navigate the program fine and some functionality of the program does infact work. Its just when i click on a certain button of the program it starts to load forever
When the program is launched from the command line it works perfectly and the same button performs near instantaneously
I just want to know where the problem could lie. Should i look more into the java program to find out what that function does differently than other functions that work with Matlab 2019a or could the issue lie with how i launch the program from Matlab. I launch it with this command:
fullpath = mfilename('fullpath')
javacmd = ['START "" /B "C:\Program Files\Java\jdk1.8.0_361\bin\java.exe" -Djna.library.path="C:\bit9prog\dev\app1\Project1\bin;" -jar ' fullpath '\..\..' '\java\Project1\target\Project1.jar'];
dos_cmd = sprintf('%s %s %s %s', javacmd, pwd);
system(dos_cmd);
If i need to give more background information for clarity do let me know
Réponses (0)
Catégories
En savoir plus sur Call Java from MATLAB dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!