开发者

.class path api java

开发者 https://www.devze.com 2023-01-05 11:32 出处:网络
I would like to insert an API java into a web page. Even with such an easy code: applet code = \'Ejs.Simulations._apps._examples.HVmin\'

I would like to insert an API java into a web page.

Even with such an easy code:

applet code =
'Ejs.Simulations._apps._examples.HVmin'

archive = 'Ejs/Simulations/_apps/_examples/HVmin/hVmin.jar',

width = 300, 
height = 300 />

I get this error:

cargar: clase Ejs.Simulations._apps._examples.HVmin not found.
java.lang.ClassNotFoundException: Ejs.Simulations._apps._examples.HVmin
at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.IOException: open HTTP connection failed:http://localhost/开发者_C百科blanca/Ejs/Simulations/_apps/_examples/HVmin.class
at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unknown Source)
at sun.plugin2.applet.Applet2ClassLoader.access$000(Unknown Source)
at sun.plugin2.applet.Applet2ClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
... 7 more
Excepción: java.lang.ClassNotFoundException: Ejs.Simulations._apps._examples.HVmin

I don't know where to put HVmin.class, I have tryed in differents paths with the same result.

The file HVmin.class is in this path: C:\xampp\htdocs\blanca\Ejs\Simulations\_apps\_examples\HVmin

Any help, please?

Thanks in advance


Just put that class in the .jar file with the rest of the applet.

0

精彩评论

暂无评论...
验证码 换一张
取 消