A java.lang.NullPointerException occurs when a Java application or Java applet has been badly coded. Typically, the Java program (and consequently, the programmer) attempted to access the reference or handle to a Java object that did not exist.
Here's an analogy that may help:
You have a piece of land on which you intend to build your own house, but you haven't built it yet.
This is the equivalent of creating (or owning) a Java object reference (also called an address).
Before you build the house, you accidentally give out your address to people, saying "That's my home address" (even though there's nothing there, not even a sign saying "My House").
This is the equivalent of wrongly using the Java object reference (or address) without actually having created a Java object within it.
The postman, your friends and your relatives drive to the address but find nothing there and think it's an error.
This is the equivalent of getting a NullPointerException.
If you're seeing the exception when using an existing Java application what displays charts, then the application has been badly coded.
The wrong n' dirty way of quickly solving (or actually suppressing) the exception is to encapsulate the offending code in a try-catch block and handle the catch in some quiet, elegant way.
The right way of solving the exception is to figure out the line causing the problem, and trace it's source, reason and data.