The following are two problems I have encountered. They are for reference only.
A. Jasper report NULL pointer exception use ireport3.7.3 to create a template and compile it into a. Jasper file,ProgramAn error occurred while throwing a null pointer during report generation. (The jar package used by the program is jasperreports-3.5.3.jar)
The reason is that the jar package used to compile the Jasper file is different from the jar package version used to call the jarsper file to generate the report. The jar package version for ireport3.7.3 is 3.7.3 (iReport-3.7.3 \ ireport \ modules \ ext \ jasperreports-3.7.3.jar) // from the irport installation directory, find the jar package for the corresponding directory
B. exception in thread "Main" Java. lang. noclassdeffounderror: ORG/codehaus/groovy/control/compilationfailedexception
2010.07.05 is because the language option in the template is grovvy by default. Select Java. The default ireport option should be modified here. Otherwise, the newly created template language is grovvy C by default. third, cannot assign instance of net. SF. jasperreports. engine. base. jrbasestatictext to field net. SF. jasperreports. engine. base. jrbaseparagraph. paragraphcontainer of Type net. SF. jasperreports. engine. jrparagraphcontainer in instance of net. SF. jasperreports. engine. base. jrbaseparagraph // you may not be able to go to bed. tnnd Java: You are dead! // jasperfillmanager. fillreport (path, null, new jremptyda Tasource (); // ireport 3.0 compiled Jasper file can pass // ireport3.6.0 compiled Jasper file can not pass, lack of this package groovy-all-1.7.5.jar // ireport4.5 can not pass, out of this error, Java. lang. classcastexception: cannot assign, no solution, no matter what you go to bed, Java is an idiot, so many packages are wasted on compilation, can we do something that contributes to society?