Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

passing json as datasource to jasper report library

<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.1.1.final using JasperReports Library version 6.1.1  -->
<!-- 2015-10-22T13:45:32 -->
<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="Blank_A4_2" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="9e494ebe-c1fb-4448-bcee-38994e9720f7">
    <!--property name="net.sf.jasperreports.json.source" value="emp.json"/-->
    <queryString language="json">
        <![CDATA[employees]]>
    </queryString>  
    <field name="firstName" class="java.lang.String">
        <fieldDescription><![CDATA[firstName]]></fieldDescription>
    </field>
    <field name="lastName" class="java.lang.String">
        <fieldDescription><![CDATA[lastName]]></fieldDescription>
    </field>
    <background>
        <band splitType="Stretch"/>
    </background>
    <detail>
        <band height="125" splitType="Stretch">
            <textField>
                <reportElement x="100" y="0" width="100" height="30" uuid="02b279da-3795-4655-8571-5a36a3ef378c"/>
                <textFieldExpression><![CDATA[$F{firstName}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement x="0" y="0" width="100" height="30" uuid="671e61ad-8d8f-48cb-969f-78c05a516398"/>
                <text><![CDATA[firstName]]></text>
            </staticText>
            <textField>
                <reportElement x="100" y="30" width="100" height="30" uuid="9d53f46f-a252-48b3-9213-8c3092c29f49"/>
                <textFieldExpression><![CDATA[$F{lastName}]]></textFieldExpression>
            </textField>
            <staticText>
                <reportElement x="0" y="30" width="100" height="30" uuid="3b49affb-685a-4df2-a872-c0e6fdcab94b"/>
                <text><![CDATA[lastName]]></text>
            </staticText>
        </band>
    </detail>
</jasperReport>
Comment

PREVIOUS NEXT
Code Example
Javascript :: how to write a range of numbers in if condition js 
Javascript :: sort array in ascending order javascript 
Javascript :: what is package.json 
Javascript :: decode jwt token without library 
Javascript :: how to append a data to list in redux 
Javascript :: closures 
Javascript :: javascript custom modal 
Javascript :: queryselector for jquery 
Javascript :: nodejs beautifulsoup 
Javascript :: pwa clear cache 
Javascript :: Generate a random Id safely 
Javascript :: how to disable button if errors object isnt empty in react hook form 
Javascript :: how fetch multiple data in javascript react 
Javascript :: use the AJAX XMLHttpRequest object in Javascript to send json data to the server 
Javascript :: inline styling react 
Javascript :: max string size javascript 
Javascript :: words counter in javascript 
Javascript :: to upper case 
Javascript :: jQuery exists function 
Javascript :: iframe content zoom in and zoom out jquery 
Javascript :: populate modal from table 
Javascript :: react-anime 
Javascript :: es6 spread assign nested object 
Javascript :: react array if id is present do not add element 
Javascript :: how to access ::after Pseudo-Elements from javascript 
Javascript :: object destructuring es6 
Javascript :: json parameter name javascript 
Javascript :: how to make a function in javascript 
Javascript :: iterating over a string 
Javascript :: javascript if function multiple conditions 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =