Borrar filtros
Borrar filtros

how to invoke java program from matlab

2 visualizaciones (últimos 30 días)
Neha
Neha el 6 de Mayo de 2011
Hie.
I am working on a project where I need to invoke java code from MATLAB, either from command window or from a .m file.
I tried using command system('java myProg_class'), where 'myProg_class is class file of my program and it's saved in the default MATLAB directory. But I'm getting error that 'java' commannd isn't recognized.
Please someone help me with this ASAP....
thanks in advance.
--
Neha

Respuestas (1)

Kaustubha Govind
Kaustubha Govind el 6 de Mayo de 2011
The syntax that you are using is used to invoke the Java interpreter from the system shell. You need to compile your code into a .jar or .class file to be able to use it from MATLAB. Please see Using Java Libraries from MATLAB for more information.
  1 comentario
Neha
Neha el 18 de Mayo de 2011
thank u Kaustubha for replying.
I did a go through of recommended topics. My problem yet is I'm not very clear what's the direct method to call a java program, I dont want to do conversion into Matlab, I just wish to run my java program in Matlab. And handle its output.
Plz help me with this.
You can also mail me @ neha.revari@gmail.com

Iniciar sesión para comentar.

Categorías

Más información sobre Call Java from MATLAB en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by