File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JNLP and Web Start and the fly likes Problem launching app through web-server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » JNLP and Web Start
Bookmark "Problem launching app through web-server" Watch "Problem launching app through web-server" New topic

Problem launching app through web-server

David Irwin
Ranch Hand

Joined: Mar 25, 2004
Posts: 82
I've developed an application that I would like to launch via webstart. Running the application locally via:

works fine. The application launches with no problem. The jar file also runs fine if I run it using:

However, when I put the same JAR and JNLP file (edited to match the updated directory location) in the webserver directory, I get a java.lang.NoClassDefFoundError exception. Here's the JNLP file:

I'm using the new swing-layout-1.0.jar file (from Netbeans Matisse) and it's included in the JExcel.jar file in a /lib directory. Like I said, it all runs fine when I run the jar file from a command line. My question is this: why does it run fine from the command line but won't run from my web-server?

[ February 24, 2006: Message edited by: David Irwin ]
Alex Kravets
Ranch Hand

Joined: Jan 24, 2001
Posts: 476
I think it has something to do with signing the jars. I've read that if you have third party jar file, in order to use it in your webstart application you need to sign it. But you can't because it's not yours. There are couple of solution, one of them is to create another jnlp file in which you refer to the third party jar file and in turn use that jnlp in your main jnlp.
This also might be helpful:

All right brain, you don't like me and I don't like you, but let's just do this one thing so I can get back to killing you with beer.<br /> <br />- Homer Simpson
I agree. Here's the link:
subject: Problem launching app through web-server
It's not a secret anymore!