You should check the condition to show those elements. And also check the font of the textfield. If the font does not support your language, the text field will be blank.
Just create a subDataset. Then create a new dataSource base on your input parameters. Similar to the comment on this topic but you can change your subDataset fields: https://community.jaspersoft.com/questions/1157291/there-way-pass-list-object-datasource-instead-custom-class-object
In your picture, I can not know which is the text field and which is your subreport. Can you please draw again and show me which element in your screenshot. I will help you.
In my experience, the width of the text field can not be changed by the content inside it. So, the background color should fit with the width of the text field that you defined. It can not make the text field bigger or something like that.
Try to add these repositories: jasperreports http://jasperreports.sourceforge.net/maven2 jaspersoft-third-party http://jaspersoft.artifactoryonline.com/jaspersoft/third-party-ce-artifacts/ [/code]
<textField textAdjust="StretchHeight"> <reportElement x="0" y="0" width="1520" height="15" uuid="6cb61704-2f0a-4b05-b714-f0219175f001"> <property name="com.jaspersoft.studio.element.name" value="content"/> </reportElement> <box topPadding="35" leftPadding="35" bottomPadding="35" rightPadding="35"/> <textFieldExpression><![CDATA[$F{point4}]]></textFieldExpression></textField>[/code]Just use textAdjust="StretchHeight" in your text field. It's will be stretch base on the content inside.
Write your own method to do it. This is not related to Jasper Report. And I think you can use google normally. When I search google with keyword: "number to word code", I received 3m results. https://stackoverflow.com/questions/3911966/how-to-convert-number-to-words-in-java
Try using a Text field. Then modify the Markup to HTML. Finally, add HTML code to the TextField's textFieldExpression and STYLE="background: #your-color-code" to your HTML tag.