|
From: Davide P. <dav...@sp...> - 2012-01-17 17:20:25
|
Hi, i created a report with iReport 4.1.3 in which I have included a barcode EAN128 using barcode4j 2.0. The code that I want to print is /020807680901146415140501370000005610I12246711 /which contains 4 items Indicod (02) n14 (15) n6 (37) n8 (10) AN9. This is the jrxml code: /<componentElement> <reportElement x="22" y="18" width="200" height="50"/> <jr:EAN128 xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd" moduleWidth="2.0" textPosition="bottom"> <jr:codeExpression><![CDATA["020807680901146415140501370000005610I12246711"]]></jr:codeExpression> </jr:EAN128> </componentElement> / The problem is that the third item (37) has not a fixed length (max 8) and I should insert the Group separator charter. As a matter of fact when I run the report I recieved error, / java.lang.IllegalArgumentException: Variable length field "0000005610I12246711" too long! Length should be 8 at the most! Accepted start of Message: "(02)08076809011464(15)140501(37)" / I can't figure out how to insert the GS character. I tried both with unicode /0208076809011464151405013700000056\u241D10I12246711/ and html endoding /0208076809011464151405013700000056/␝/10I12246711/ with no success. Can someone help me? Thanks Davide |