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

jan.cirpka

Members
  • Posts

    2
  • 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 jan.cirpka

  1. I am using a custom datasource that implements some specific methods that are called from with the jasper .jrxml templates to fill subreports. To invoke these methods I need top downcast the REPORT_DATA_SOURCE parameter resulting in an expression like ((com.archimatetool.jasperreports.data.ViewModelDataSource)$P{REPORT_DATA_SOURCE}).getPropertiesDataSource()[/code]This all works very nicely - unless I want to invoke the Preview capailities of Jasperstudio. Necessarily it fails as the downcast requires the presence of the java library. So I wonder if I can configure my Jasperstudio in such a way that my custom libraries will get resolved? That said, I wonder if I can somehow specify within Jasperstudio the file that underlies my custom datasource? I know that this is possible for XML datasources.
  2. I like to beautify the Table of Contents which I created based on the sample given. In particular I would like the leaders - the (dotted) line up to the page number on the right - to fit the remaining(!) length of the line. Such features are for example available in the out of the box TOC templates of Microsoft Word. And to make things even more complex, ideally also handling multi-line scenarios (due to stretching). As you see in the included example I got to some point. VBut the dots are overlapping the text ... kind of obvious as I did place overlapping textFields. Is there a better way? And secondly tyou see in the last row with the very long text that the formatting is almost correct ... but why are the dots in the middle? Of course, with the output goes some .jrmxl code so that you all can see what I've done: <detail> <band height="15" splitType="Stretch"> <printWhenExpression><![CDATA[$F{level} == 1]]></printWhenExpression> <textField isStretchWithOverflow="true" hyperlinkType="LocalAnchor"> <reportElement style="Bold" x="40" y="0" width="460" height="15" isRemoveLineWhenBlank="true"/> <textFieldExpression><![CDATA[$F{label}]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> <staticText> <reportElement style="Bold" positionType="FixRelativeToBottom" stretchType="ContainerBottom" x="150" y="0" width="375" height="15" isRemoveLineWhenBlank="true" /> <textElement textAlignment="Right"/> <text><![CDATA[________________________________________________________________________________]]></text> </staticText> <textField isStretchWithOverflow="true" evaluationTime="Auto" hyperlinkType="LocalAnchor"> <reportElement positionType="FixRelativeToBottom" stretchType="ContainerBottom" x="525" y="0" width="30" height="15" isRemoveLineWhenBlank="true" /> <textElement textAlignment="Right"/> <textFieldExpression><![CDATA[$V{PAGE_NUMBER} + $F{pageIndex} + 1]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> </band> <band height="15" splitType="Stretch"> <printWhenExpression><![CDATA[$F{level} == 2]]></printWhenExpression> <textField isStretchWithOverflow="true" hyperlinkType="LocalAnchor"> <reportElement positionType="Float" x="75" y="0" width="425" height="15" isRemoveLineWhenBlank="true"/> <textFieldExpression><![CDATA[$F{label}]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> <hyperlinkTooltipExpression><![CDATA[$F{label}]]></hyperlinkTooltipExpression> </textField> <staticText> <reportElement positionType="FixRelativeToBottom" stretchType="ContainerBottom" x="150" y="0" width="375" height="15" isRemoveLineWhenBlank="true" uuid="c6cf49ba-d7d0-42fa-9b2c-36ba110e91f4"/> <textElement textAlignment="Right" verticalAlignment="Top"/> <text><![CDATA[. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .]]></text> </staticText> <textField isStretchWithOverflow="true" evaluationTime="Auto" hyperlinkType="LocalAnchor"> <reportElement positionType="FixRelativeToBottom" stretchType="ContainerBottom" x="525" y="0" width="30" height="15" isRemoveLineWhenBlank="true" "/> <textElement textAlignment="Right"/> <textFieldExpression><![CDATA[$V{PAGE_NUMBER} + $F{pageIndex} + 1]]></textFieldExpression> <hyperlinkAnchorExpression><![CDATA[$F{label}]]></hyperlinkAnchorExpression> </textField> </band></detail>[/code]Any help would be greatly appreciated.
×
×
  • Create New...