applets and multiple jar files

D

Digital Puer

Hi, I am preparing an applet that will be placed in a jar
file. The problem is that the applet uses other jar files.
What is the best way to organize all the files for
downloading, and how should I write the <applet ...>
tags to handle this situation?

Specifically, if my class MyClass.class is placed in
MyJar.jar, and if MyClass uses JarFile1.jar and JarFile2.jar,
would the <applet> tag look like this:

<applet code="MyClass.class"
archive="MyJar.jar JarFile1.jar JarFile2.jar"
width=120 height=120>
</applet>
 
A

Andrew Thompson

Digital said:
<applet code="MyClass.class"
archive="MyJar.jar JarFile1.jar JarFile2.jar"
archive="MyJar.jar,JarFile1.jar,JarFile2.jar"

width=120 height=120>
</applet>

HTH
 
R

Roedy Green

Hi, I am preparing an applet that will be placed in a jar
file. The problem is that the applet uses other jar files.
What is the best way to organize all the files for
downloading, and how should I write the <applet ...>
tags to handle this situation?

Put the other jars is the Class-Path manifest of the master jar and
build an index to the other jars so that loader won't have to download
a jar unless in really needs it. See http://mindprod.com/jar.exe.html

Alternatively, you must mention the jars in the archive tag. See
http://mindprod.com/jgloss/applet.html
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top