Results 21 to 25 of 25
Thread: Add 3D applet to html page
- 07-25-2010, 02:58 PM #21
Sorry, I have no experience or knowledge about using jar files from different locations.Can you put ALL of the files in the same folder? jar and html
I've never used the JNLP appletlauncher.
Have you read the doc at https://applet-launcher.dev.java.net/Last edited by Norm; 07-25-2010 at 03:25 PM.
- 07-30-2010, 01:51 PM #22
When I add the code of java3d.dev.java.net for the FourByFour applet:
that works, but when I get the source-code of FourByFour on the internet add compile it by myself and add it into a .jar file and add the same applet code but only my own .jar, but that don't work.Java Code:<applet code="org.jdesktop.applet.util.JNLPAppletLauncher" width=800 height=400 archive="http://download.java.net/media/java3d/webstart/test/j3d-examples.jar, http://download.java.net/media/applet-launcher/applet-launcher.jar, http://download.java.net/media/java3d/webstart/release/j3d/latest/j3dcore.jar, http://download.java.net/media/java3d/webstart/release/j3d/latest/j3dutils.jar, http://download.java.net/media/java3d/webstart/release/vecmath/latest/vecmath.jar, http://download.java.net/media/jogl/builds/archive/jsr-231-webstart-current/jogl.jar, http://download.java.net/media/gluegen/webstart/gluegen-rt.jar"> <param name="codebase_lookup" value="false"> <param name="subapplet.classname" value="org.jdesktop.j3d.examples.four_by_four.FourByFour"> <param name="subapplet.displayname" value="Java 3D Four by Four Applet"> <param name="jnlpNumExtensions" value="1"> <param name="jnlpExtension1" value="http://download.java.net/media/java3d/webstart/release/java3d-latest.jnlp"> <param name="progressbar" value="true"> <param name="noddraw.check" value="true"> </applet>
I don't know how I can fix it....
- 07-30-2010, 02:04 PM #23
Can you show your APPLET tag code for when it doesn't work?
Also look at the browser's java console.
When I tried using a locally compiled version of the 4x4 program I get a security error:
java.lang.SecurityException: trusted loader attempted to load sandboxed resource from file:/D:/JavaDevelopment/Testing/AppletLauncher/3D_Jars/local4x4.jarLast edited by Norm; 07-30-2010 at 02:54 PM.
- 08-01-2010, 11:27 AM #24
The code on my previous post is het applet tag code for when it doesn't work.
(the subapplet.classname is for my applet name, for load it with the applet-launcher, but that errors)
The browser's concole error is:
Java Code:java.security.AccessControlException: acces denied (java.net.SocketPermissions download.java.net connect,accept,resolve) at java.security.AccessControlContext.checkPermission(AccesControlContext.java:323) at java.security.AccessController.checkPermission(AccessController.java:546) at java.lang.SecurityManager.checkPermission(SecurityManager.java:532) at java.net.URLClassLoader$4.run(URLClassLoader.java:515) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.getPermissions(appletClassLoader.java:238) at java.security.SecureClassLoader..getProtectionDomain(SecureClassLoader.java:235) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) at java.net.URLClassLoader.defineClass(URLClassLoader.java:283) at java.net.URLClassLoader.access$000(URLClassLoader.java:58) at java.net.URLClassLoader$1.run(URLClassLoader.java:197) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at sun.applet.AppletClassLoader.findClass(AppletClassLoader.java:172) at java.lnag.ClassLoader.loadClass(classLoade.rjava:307) at sun.applet.AppletClassLoader.loadClass(ClassLoader.java:144) at java.lang.ClassLoader.loadClass(ClassLoader.java:248) at sun.applet.AppletClassLoader.loadCode(AppletClassLoader.java:654) at sun.applet.AppletPanel.createApplet(AppletPanel.java:785) at sun.applet.AppletPanel.runLoader(AppletPanel.java:714) at sun.applet.AppletPanel.run(AppletPanel.java:368) at java.lang.Thread.run(Thread.java:619)
- 08-01-2010, 01:07 PM #25
Because the applet launcher has permission to do things like read and write on your system, the JVM won't allow any code mixed in with the launcher to execute that does NOT have permissions.
You can give your code permission by signing the jar file your code is in.
Or for your private testing you might be able give your code permission by putting an entry in the .java.policy file by using the policytool program.
Similar Threads
-
redirect to html page
By simo_mon in forum Java ServletReplies: 3Last Post: 02-12-2009, 05:18 PM -
Applet - Displaying an HTML page with a selected resolution
By Java Tip in forum Java TipReplies: 0Last Post: 03-10-2008, 02:36 PM -
How to view applet from html page.
By jwzumwalt in forum Java AppletsReplies: 2Last Post: 11-24-2007, 04:21 AM -
HTML page
By bbq in forum New To JavaReplies: 1Last Post: 07-05-2007, 03:46 AM -
Create a Applet in the page HTML
By Daniel in forum Java AppletsReplies: 2Last Post: 07-04-2007, 07:52 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks