0

I am getting a NoClassDefFoundError at runtime with an android app created in eclipse. I have seen a lot of potential solutions to this problem involving lots of cleaning and restarting eclipse (none of which have worked) as well as some more technical ones involving checking that the CLASSPATH is correct. Unfortunately I have only a sketchy idea of what my classpath is, but more critically, I have no idea how to view what it currently is!

The NoClassDefFoundError problem appeared when I tried to use a map fragment with a tablistener. i.e. a class which starts with:

public class MapFragmentWithTabListener extends SupportMapFragment implements TabListener
{
//...

and the precise error is:

java.lang.NoClassDefFoundError: com.mycompany.myapp.MapFragmentWithTabListener

The tablistener is part of actionabrshirlock, other aspects of which have been working fine. The SupportMapFragment is new to my project and so suspect that some aspect of this may not be set up correctly somewhere (though it does compile without error). Should my CLASSPATH contain some text indicating that it knows all about SupportMapFragment and where it is?

EDIT: Indeed the question about ADT 22 does fix my bug. But I'd still like the answer to the title of my question. Is the classpath the sum total of the info in the four tabs of "java build path" within the properties of my project? Or just one of the tabs? Or something else entirely?

Community
  • 1
  • 1
Mick
  • 8,284
  • 22
  • 81
  • 173
  • 1
    possible duplicate of [Libraries do not get added to APK anymore after upgrade to ADT 22](http://stackoverflow.com/questions/16596969/libraries-do-not-get-added-to-apk-anymore-after-upgrade-to-adt-22) – Selvin May 28 '13 at 11:34
  • have you updated at to rev 22?. If so right click on your project. Goto Properties. Java Build path. Goto Order Export tab. Makes sure you have checked Android Private Libraries for both Library project and your android project. Clean and build. – Raghunandan May 28 '13 at 11:34

0 Answers0