Web Start problem


E

emf

I'm learning Web Start using eclipse but from a book that uses the
command prompt method. So in eclipse I have 2 projects: the first
contains files downloaded from the book's website (and does not contain
the programs in packages, and in the second I copy and compile the same
files but in packages as eclipse requires.

The jnlp file in the first project:

=============
<?xml version="1.0" encoding="UTF-8"?>

<jnlp spec="1.0+"
codebase="file:///C:/MyStuf~1/MyFile~1/Java/worksp~1/JIES/10-Dep~1"
href="Lotto.jnlp">

<information>
<title>Lotto Application</title>
<vendor>Java In Easy Steps</vendor>
<homepage href="http://www.ineasysteps.com" />
<offline-allowed/>
</information>

<resources>
<jar href="Lotto.jar"/>
<j2se version="1.6+"
href="http://java.sun.com/products/autodl/j2se"/>
</resources>

<application-desc main-class="Lotto"/>

</jnlp>
=============

works just fine and the program runs OK.

However, the jnlp of the second project:

=============
<?xml version="1.0" encoding="UTF-8"?>

<jnlp spec="1.0+"
codebase="file:///C:/MyStuf~1/MyFile~1/Java/worksp~1/JavaIn~1/10_Dep~1/"
href="Lotto.jnlp">

<information>
<title>Lotto Application</title>
<vendor>Java In Easy Steps</vendor>
<homepage href="http://www.ineasysteps.com" />
<offline-allowed/>
</information>

<resources>
<jar href="Lotto.jar"/>
<j2se version="1.6+"
href="http://java.sun.com/products/autodl/j2se"/>
</resources>

<application-desc main-class="Lotto"/>

</jnlp>
=============

does not find the jnlp file (java.io.FileNotFoundException: The system
cannot find the path specified).

Can the problem be that the program in the second project inside the jar
is in a package? If not, what else could the problem be?

Thanks,

emf
 
Ad

Advertisements

J

John B. Matthews

[...]
<?xml version="1.0" encoding="UTF-8"?>

<jnlp spec="1.0+" [...] > [...]

<application-desc main-class="Lotto"/>

</jnlp>
=============

does not find the jnlp file (java.io.FileNotFoundException: The
system cannot find the path specified).

Can the problem be that the program in the second project inside the
jar is in a package?

Yes; as a concrete example, cited below, the main class is in a package
named "draw":

<application-desc main-class="draw.GraphPanel"/>

If not, what else could the problem be?

What did you try? What happened when you tried it?

More resources may be found here:

<http://stackoverflow.com/tags/java-web-start/info>
 
R

Roedy Green

does not find the jnlp file (java.io.FileNotFoundException: The system
cannot find the path specified).

JWS looks for a JNLP file twice, once for a URL you specify, (often
cached) then it looks inside that file for a link to the most
up-to-data copy.

You seem to be using short DOS filenames. I would avoid that. Their
support is optional.

Do you have two copies of the JNLP? What are their precise file
names?

Java is case sensitive. Make sure all your names have the precise
case.

Normally there are no file: urls in jnlp. There should not be any if
you are trying to use this on the web.
--
Roedy Green Canadian Mind Products http://mindprod.com
The first 90% of the code accounts for the first 90% of the development time.
The remaining 10% of the code accounts for the other 90% of the development
time.
~ Tom Cargill Ninety-ninety Law
 
R

Roedy Green

<jnlp spec="1.0+"

We are on JNLP version 6 . If you specify 1.0 you must limit yourself
drastically.
--
Roedy Green Canadian Mind Products http://mindprod.com
The first 90% of the code accounts for the first 90% of the development time.
The remaining 10% of the code accounts for the other 90% of the development
time.
~ Tom Cargill Ninety-ninety Law
 
Ad

Advertisements

Ad

Advertisements


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

Top