Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Java Applet NoSuchMethodError

Posted on 2011-03-15
8
Medium Priority
?
562 Views
Last Modified: 2012-08-13
Hello I have an applet that I'am trying to launch, and i notice when deploying it to a web page using the applet code of

<applet code="ddcg.NoteCount.class" width="350" height="200" archive="axmsound.jar, ddcg.jar">
</applet>

Now when i try to launch it I notice nothign pops up, so upon further investigation into the java console I realize that the method getPitchName()  is not found.  Now the thing is ddcg is dependant on axmsound to work, and the method getPitchName() exist in axmsound.jar, where as the application itself lives in the ddcg.jar, and the application code that live inside the ddcg.jar imports some of the classes and methods inside axmsound

So basically how can I make the applet detect the axmsound? it seems to work fine when working in netbean but when it comes to actually launching my applet it doesnt work.  Help is greatly appreciated thank you!.
0
Comment
Question by:Alanf718
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 1000 total points
ID: 35140843
Make sure the same jars are being deployed to the web that are using in NB

Is there a url we can try yet?
0
 
LVL 47

Expert Comment

by:for_yan
ID: 35140912
Is getPitchName() a static method?
If it is, you should prefic it with the class name.
If not you should instantiate instance of some class
and then use it rto run this method - you'll be rather missing class
than missing method, if your axmsound.jar is inaccessible
0
 

Author Comment

by:Alanf718
ID: 35141039
getPitchName() is in fact a static method, and I only have the code existing on my local machine.  but I assure you that the jar files are the same, wether or not Iam "declaring" them right or whatever the case may be in the html applet code is another issue.

The begging of the error in ints interity is

Exception in thread "thread applet-ddcg.NoteCount.class-1" java.lang.NoSuchMethodError: axmsound.data.Pitch.getPitchName(I)...
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 86

Expert Comment

by:CEHJ
ID: 35141070
>> but I assure you that the jar files are the same,

How do you know?
0
 
LVL 47

Expert Comment

by:for_yan
ID: 35141100
One not very elegant method, but the one which may be useful when having issues with applets is to
expand this jar into the code base of the Applet


As far as I recall, I used to have 'No such method" errors when I had some version mismatches
0
 
LVL 26

Assisted Solution

by:ksivananth
ksivananth earned 1000 total points
ID: 35141104
make sure you have right version of axmsound.jar and then try changing the order of the jars in archive list...
0
 

Author Closing Comment

by:Alanf718
ID: 35141229
I tried copying the actual output jar files that netbeans packaged for me as opposed to the ones i was jarring myself, and it worked! seemed like the jars even though containing the same files werent the correct "version" so it wasnt being recognized, thanks for all the help!
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 35141263
:)
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

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

Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses

610 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