Solved

JAR help

Posted on 2004-04-18
9
386 Views
Last Modified: 2010-03-31
Hey i am trying to make my program into a jar file in Netbeans. But i am having problems and i  am not sure where.
I think i want it to be a stand alone jar file, though im not 100% on what that means.
But not be stuck on a windows machine, i need it to work for Mac also.


my Manifest is:


Manifest-Version: 1.0
Main-Class: SP1
Created-By: NetBeans IDE
Specified-By: Kenjar.jarContent

And all the files i want to include, i have a screen shot of-
http://www.geocities.com/drunkentiger765/JavaMediaPlayer/temp1.JPG

Thanks for you help and quickness like always
0
Comment
Question by:DrunkenTigerDDD
9 Comments
 

Author Comment

by:DrunkenTigerDDD
ID: 10854332
i get this problem when i try

java.lang.NoClassDefFoundError: javazoom/jl/player/advanced/PlaybackListener
Exception in thread "main" 
0
 
LVL 4

Expert Comment

by:91mustang
ID: 10854429
make sure you include the entire folder structure: javazoom/jl/player/advanced/PlaybackListener
0
 

Author Comment

by:DrunkenTigerDDD
ID: 10854454
well i add the jar file, i have also tryed adding the directory with all the classes in it, neither are working
0
ScreenConnect 6.0 Free Trial

At ScreenConnect, partner feedback doesn't fall on deaf ears. We collected partner suggestions off of their virtual wish list and transformed them into one game-changing release: ScreenConnect 6.0. Explore all of the extras and enhancements for yourself!

 

Author Comment

by:DrunkenTigerDDD
ID: 10854550
help
0
 
LVL 4

Expert Comment

by:91mustang
ID: 10854579
is javazoom/jl/player/advanced/PlaybackListener in a jar file already?
0
 
LVL 4

Accepted Solution

by:
91mustang earned 250 total points
ID: 10854610
>>is javazoom/jl/player/advanced/PlaybackListener in a jar file already?
if that is the case, it will not work.. you can not have a jar inside another jar. you have to use the classpath attribute in the manifest to point to where the 3rd party jar is. here are a few links:

http://forum.java.sun.com/thread.jsp?forum=22&thread=480118&tstart=0&trange=15

http://experts-exchange.com/Programming/Programming_Languages/Java/Q_20852941.html

The last post in both threads will be the important part. your best option is to do Jimmack's suggestion, where he deploys in a zip file, so then he knows the external jar file is in the correct location every time
0
 
LVL 30

Expert Comment

by:Mayank S
ID: 10856846
0
 
LVL 9

Expert Comment

by:mmuruganandam
ID: 10857371
The problem is

In your Jar, the PlaybackListener is having an extra folder classes/javazoom/jl/player/advanced/PlaybackListener

It should be

javazoom/jl/player/advanced/PlaybackListener

Then your program will work.

Jar your files from javazoom package.  Or move the javazoom package to the root.  It shouldnt be with in classes folder in the jar file.

Hope this helps.


Regards,
Muruga
0
 
LVL 4

Expert Comment

by:91mustang
ID: 10942763
thanks :-)
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question