Jump to content

paulchurchward

Members
  • Posts

    11
  • Joined

  • Last visited

paulchurchward's Achievements

Apprentice

Apprentice (3/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Collaborator Rare

Recent Badges

0

Reputation

  1. NM I overlooked the fact that it wouldn't draw a line connecting two point is there is no X axis value for that set. Thnx
  2. hello, I have a chart that plots two sets of data. It plots both sets of data fine, but the second set of data doesn't have the points connected with a line running through them Code:<?xml version="1.0" encoding="UTF-8"?><jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="opstatsreport" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <parameter name="title" class="java.lang.String"/> <parameter name="reportDetails" class="java.lang.String"/> <parameter name="xAxisDescription" class="java.lang.String"/> <parameter name="yAxisDescription" class="java.lang.String"/> <field name="runDate" class="java.util.Date"/> <field name="runTimeInMins" class="java.lang.Integer"/> <field name="jobName" class="java.lang.String"/> <background> <band splitType="Stretch"/> </background> <title> <band height="48" splitType="Stretch"> <textField> <reportElement x="0" y="0" width="543" height="40"/> <textElement> <font size="12" isBold="true" isItalic="false" isStrikeThrough="false"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$P{title}]]></textFieldExpression> </textField> </band> </title> <summary> <band height="424" splitType="Stretch"> <textField> <reportElement x="0" y="0" width="526" height="54"/> <textElement/> <textFieldExpression class="java.lang.String"><![CDATA[$P{reportDetails}]]></textFieldExpression> </textField> <lineChart> <chart renderType="draw"> <reportElement x="2" y="71" width="541" height="327"/> <chartTitle> <font size="8"/> </chartTitle> <chartSubtitle> <font size="8"/> </chartSubtitle> <chartLegend> <font size="8"/> </chartLegend> </chart> <categoryDataset> <categorySeries> <seriesExpression><![CDATA[$F{jobName}]]></seriesExpression> <categoryExpression><![CDATA[$F{runDate}]]></categoryExpression> <valueExpression><![CDATA[$F{runTimeInMins}]]></valueExpression> </categorySeries> </categoryDataset> <linePlot> <plot labelRotation="90.0"/> <categoryAxisLabelExpression><![CDATA[$P{xAxisDescription}]]></categoryAxisLabelExpression> <categoryAxisFormat labelRotation="90.0"> <axisFormat> <labelFont/> <tickLabelFont/> </axisFormat> </categoryAxisFormat> <valueAxisLabelExpression><![CDATA[$P{yAxisDescription}]]></valueAxisLabelExpression> <valueAxisFormat> <axisFormat> <labelFont/> <tickLabelFont/> </axisFormat> </valueAxisFormat> </linePlot> </lineChart> </band> </summary></jasperReport>
  3. I am using iReport actually which is how my jrxml came to be. From the attached jrxml file, can you plse show me the necessary modifications. Also, can you tell me where I possibly went wrong in iReport ? Thanks very much
  4. Im not sure what you mean by resetType, I don't see this attribute in the jrxml file. Thanks ! - Paul
  5. Thanks. That did the trick. I only see one graph now. Oddly though only the last object I put into the list that is wrapped by the JRDatasource is being graphed. ie: List<?> someList = new ArrayList<?>(); someList.add(new SomeObject(1)); someList.add(new SomeObject(1)); someList.add(new SomeObject(1)); JRDataSource = new JRBeanCollectionDataSource(someList); only the last object is showing up on the graph...
  6. Hello, I have a very simple report that only contains a single line graph. I am displaying it as a PDF froma a java web application (Using Spring). The resulting PDF is creating a multiple sets of axis and on each axis only plotting the last added data point. See attached pdf and jrxml Thanks Code: Post Edited by paulchurchward at 01/05/2011 20:56 Post Edited by paulchurchward at 01/05/2011 20:59
  7. Im trying to display a simple chart via a java web app, I have been stopped in my tracks by this exception: ClassNotFoundException org.objectweb.asm.Opcodes These are the jars im using: ant-1.7.0.jar ant-launcher-1.7.0.jar commons-beanutils-1.8.3.jar commons-collections-3.2.1.jar commons-dbcp-1.4-javadoc.jar commons-dbcp-1.4-sources.jar commons-dbcp-1.4.jar commons-digester-2.1.jar commons-logging-1.1.1.jar commons-pool-1.5.4.jar groovy-1.7.6.jar iText-2.1.5.jar jasperreports-3.7.6.jar jasperreports-fonts-3.7.6.jar jasperreports-javaflow-3.7.6.jar jcommon-1.0.15.jar jcommon-1.0.16.jar jfreechart-1.0.12.jar jfreechart-1.0.13-experimental.jar jfreechart-1.0.13-swt.jar jfreechart-1.0.13.jar jtds-1.2.4.jar junit-4.8.1.jar log4j-1.2.16.jar servlet-api-2.3.jar servlet-api-2.5.jar spring-aop-3.0.0.RELEASE.jar spring-asm-3.0.0.RELEASE.jar spring-beans-3.0.0.RELEASE.jar spring-context-3.0.0.RELEASE.jar spring-core-3.0.0.RELEASE.jar spring-expression-3.0.0.RELEASE.jar spring-jdbc-3.0.0.RELEASE-sources.jar spring-jdbc-3.0.0.RELEASE.jar spring-orm-3.0.0.RELEASE.jar spring-test-3.0.0.RELEASE-sources.jar spring-test-3.0.0.RELEASE.jar spring-tx-3.0.0.RELEASE.jar spring-web-3.0.0.RELEASE.jar spring-webmvc-3.0.0.RELEASE.jar spring-webmvc-portlet-3.0.0.RELEASE.jar Thanks in advance Code: Post Edited by paulchurchward at 01/04/2011 20:03 Post Edited by paulchurchward at 01/04/2011 20:22
  8. Hello, When I try to use the jrxml from Java, I get this exception thrown at me: net.sf.jasperreports.engine.design.JRValidationException: Report design not valid My jrxml file is attached
  9. Hi everyone, I want to use Spring MVC to display charts created with Jasper. I cannot find much in the way of clear documentation on how to do this. Everything I have found so far is either not applicable or missing steps. My requirements: - I need to display data stored in a database as a chart on an HTML page. - The query used to get the data to be charted, is driven by user input, meaning the user will select applicable dates and other parameters to plug into the query. - Spring DAO (jdbc) is being used to interface with the database. If for some reason spring jdbc won't work with jasper I can switch to a different tech like hibernate I have looked at the Spring documentation regarding Jasper, but it neglected to say how to create the jrxml file. How do I do this ? Will jasper work given my requirement that the sql queries are not static ? Thanks in advance ! Post Edited by paulchurchward at 12/24/2010 15:46 Post Edited by paulchurchward at 12/24/2010 15:47
×
×
  • Create New...