If necessary I could also upload the source code
Here's the first issue I see: In your JNLP file, the code base seems wrong.
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<jnlp
codebase="file:/C:/Users/Lasse%20Madsen/Desktop/Skole/NOEA/2.%20semester/Projekt/temapersis6/Rollespil/dist/"
href="launch.jnlp" spec="1.0+">
I'm pretty sure that your app isn't on my hard disc with the path
"file:/c:/User/Lasse Madsen/.. etc." This needs to be a path my system
can find relative to your server. It probably should start with
"http://lsmc.dk/...etc."
I've run into this problem myself with NetBeans and I don't have a fix
for it. Maybe try the NetBeans mailing list. If you find something,
please let us know.
Also you may have problems with caching when you try to edit the JNLP
file. You may need to set no-cache for the entire sub-directory tree
where it lives. This seems to be the easiest way to deal with the many
little files that applets generate.
Your mime types seem to be correct; partial download log below:
$ wget -r http://lsmc.dk/test/launch.html
--2009-12-20 07:08:43-- http://lsmc.dk/test/launch.html
Length: 731 [text/html]
--2009-12-20 07:08:44-- http://lsmc.dk/test/launch.jnlp
Length: 802 [application/x-java-jnlp-file]
When I ran it, it loaded and died with the following dump.
Exception in thread "AWT-EventQueue-0"
java.lang.ExceptionInInitializerError
at Gui.Login.<init>(Login.java:28)
at Gui.Login$4.run(Login.java:183)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown
Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown
Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown
Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.security.AccessControlException: access denied
<><><><><><><><><><>
(java.util.PropertyPermission user.dir read)
at java.security.AccessControlContext.checkPermission(Unknown
Source)
at java.security.AccessController.checkPermission(Unknown
Source)
at java.lang.SecurityManager.checkPermission(Unknown Source)
at java.lang.SecurityManager.checkPropertyAccess(Unknown
Source)
at java.lang.System.getProperty(Unknown Source)
at DBLayer.DBConnection.<init>(DBConnection.java:38)
at DBLayer.Player.DBPlayer.<init>(DBPlayer.java:33)
at CtrLayer.CtrLogin.<init>(CtrLogin.java:47)
at CtrLayer.CtrLogin.<clinit>(CtrLogin.java:33)
... 10 more
Did your remember to sign your jar? See
http://mindprod.com/jgloss/javawebstart.html
Your JNLP file looks like this:
<jnlp spec="1.0+" codebase="http://lsmc.dk/test/"
href="http://lsmc.dk/test/launch.jnlp">
<information>
<title>Rollespil</title>
<vendor>Gruppe 6</vendor>
<homepage href="null"/>
<description>Management for roleplaying</description>
<description kind="short">Rollespil</description>
</information>
<update check="timeout" policy="always"/>
<resources>
<java java-vm-args="-Djava.security.policy=applet.policy"
version="1.6+"/>
<jar href="http://lsmc.dk/test/Rollespil.jar" download="eager"
main="true"/>
<jar href="http://lsmc.dk/test/lib/swing-layout-1.0.4.jar"
download="eager" main="false"/>
<jar href="http://lsmc.dk/test/lib/AbsoluteLayout.jar"
download="eager" main="false"/>
</resources>
<application-desc main-class="Gui.Login"/>
</jnlp>
There is no applet.policy file on my machine. Normally package names
are all lower case.
You might want to add lines to your JNLP file something like this:
<homepage href="webstart/replicator.html" />
<icon href="replicator.icon64.png" width="64" height="64"
kind="default" />
<icon href="replicator.splash.png" width="128" height="128"
kind="splash" />
<!-- create desktop shortcut to run the Replicator -->
<shortcut online="true">
<desktop />
<menu submenu="The Replicator" />
</shortcut>
<resources>
<!-- requires 1.6 -->
<!-- Sun JVM -->
<java version="1.6.0_17"
href="http://java.sun.com/products/autodl/j2se" java-vm-args="-ea"
initial-heap-size="128m" max-heap-size="512m" />
<java version="1.6+"
href="http://java.sun.com/products/autodl/j2se" java-vm-args="-ea"
initial-heap-size="128m" max-heap-size="512m" />
<!-- any vendor -->
<java version="1.6+" java-vm-args="-ea" initial-heap-size="128m"
max-heap-size="512m" />
<!-- set -D system properties -->
<property name="VIA" value="website" />
--
Roedy Green Canadian Mind Products
http://mindprod.com
The future has already happened, it just isn�t evenly distributed.
~ William Gibson (born: 1948-03-17 age: 61)
Thx for the help
I also had to sign the jar-file, which I have to read about first
Thx for the help
I just had to sign the jar-file
I am so glad you told us what you discovered. I have no experience writing
applets and your solution taught me something I had not known. Likewise the
information from those who responded helped me, even though it didn't
necessarily bear on your specific situation.
--
Lew
If I see the log-in prompt, did it work?
Try validating the entire launch using JaNeLA.
<http://pscode.org/janela>
--
Andrew T.
pscode.org