Jump to content
Changes to the Jaspersoft community edition download ×

rolando_1

Members
  • Posts

    1
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by rolando_1

  1. My english is an horror and I dont have much time now to explain myself. This is a piece of code where i believe am using what you need. package workingwithjaspers; import java.io.File; import net.sf.jasperreports.engine.JRException; import net.sf.jasperreports.engine.JRParameter; import net.sf.jasperreports.engine.JasperCompileManager; import net.sf.jasperreports.engine.JasperReport; import net.sf.jasperreports.engine.util.JRLoader; /** * * @author rolo */ public class Main { /** * @param args the command line arguments */ public static void main(String[] args) throws JRException { String filename = "F:/Documents and Settings/rolo/NetBeansProjects/workingwithjaspers/out/Proyectos.jasper"; String params_array = ""; JasperReport jasperReport = (JasperReport)JRLoader.loadObject(new File(filename)); int i = 0; Object obj = null; while(i < jasperReport.getParameters().length && jasperReport.getParameters()[i++].isSystemDefined()){ params_array = jasperReport.getParameters().getName()+","+jasperReport.getParameters().getValueClassName()+","; if(jasperReport.getParameters().getDefaultValueExpression() !=null ){ obj= JasperCompileManager.loadEvaluator(jasperReport).evaluate(jasperReport.getParameters().getDefaultValueExpression()); /to be continue
×
×
  • Create New...