calling java from matlab
Afficher commentaires plus anciens
Folks:
I know that there are a few questions about this topic but I´m facing the same problem with running java with matlab. I used the simple java program bellow:
package SmartGrid;
public class teste1 {
/** * @param args */
public teste1 () {
}
public static void HelloWorld() {
System.out.println("Hello, World");
}
}
The program is stored in the folder c:\Apps\Programas em java\Portico\portico_Agent\bin\SmartGrid
so I added the java class path with the command:
javaadddpath('c:\Apps\Programas em java\Portico\pórtico_agent\bin\SmartGrid')
When I run a simple command:
x=SmartGrid.teste1();
I get this error message:
Undefined variable "SmartGrid" or class "SmartGrid.teste1".
what I am missing ?
The problem may be so simple that I cannot see the mistake.
I´d appreciate any help.
2 commentaires
Walter Roberson
le 29 Juin 2013
Did you import the class ?
andre albagli
le 30 Juin 2013
Réponses (0)
Catégories
En savoir plus sur Call Java from MATLAB dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!