Jump to content
We've recently updated our Privacy Statement, available here ×

Displaying object as images inside a list component in iReport


psl003

Recommended Posts

Hello.

          I have to display  object as image  inside a list component in iReport based on a particular count(here using intNote  ). I have tried this way...But no image is dispalyed...while using image path from specific location images are displayed...how can i dispaly object as  images inside a list component ..please any one help me as soon as possible.......Thanks.........

 

<subDataset name="Q2">
        <field name="strVert" class="java.awt.Image"/>      
    </subDataset>

<field name="intNote" class="java.lang.Integer"/> 

<componentElement>
                <reportElement x="130" y="72" width="25" height="35"/>
                <jr:list xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd" printOrder="Horizontal" ignoreWidth="true">
                    <datasetRun subDataset="Q2">
                        <dataSourceExpression><![CDATA[new net.sf.jasperreports.engine.JREmptyDataSource($F{intNote})]]></dataSourceExpression>
                    </datasetRun>
                    <jr:listContents height="35" width="25">
                        <image isUsingCache="false">
                            <reportElement x="3" y="10" width="16" height="17" forecolor="#FFFFFF"/>
                            <graphicElement>
                                <pen lineWidth="1.25"/>
                            </graphicElement>
                            <imageExpression class="java.awt.Image"><![CDATA[$F{strVert}]]></imageExpression>
                        </image>
                    </jr:listContents>
                </jr:list>
            </componentElement>

 



Post Edited by psl003 at 02/24/2011 06:17



Post Edited by psl003 at 02/24/2011 06:19
Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...