Jump to content
JasperReports Library 7.0 is now available ×

illegalArgumentException when filling report


2004 IR Help

Recommended Posts

By: thejstroker - thejstroker

illegalArgumentException when filling report

2005-03-03 10:25

I'm getting an illegal argument exception when I try to fill my report which is just a simple table. I have included the stack trace, although it's not very useful in this case, as it mentions a method in JRFillTextField, but doesn't say which textfield is causing it. Nothing appears to stand out about any of the textfields in my report

If there is already a similar post I apologize. I searched and didn't find anything helpful.

 

com.intervera.util.DVRuntimeException: java.lang.RuntimeException: java.lang.IllegalArgumentException: Can't add attribute to 0-length text

at com.intervera.util.DVPoolThread.run(DVPoolThread.java:91)

 

Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: Can't add attribute to 0-length text

at com.intervera.format.DVAbstractJasperFormatter.format(DVAbstractJasperFormatter.java:104)

at com.intervera.adapter.DVTextOutputFileAdapter.write(DVTextOutputFileAdapter.java:80)

at com.intervera.rules.io.WriteDataGroup_DG.applyRule(WriteDataGroup_DG.java:236)

at com.intervera.util.DVDataGroup.applyRule(DVDataGroup.java:4201)

at com.intervera.util.DVDataGroupManager.applyRule(DVDataGroupManager.java:517)

at com.intervera.rules.base.DVRulesEngine.applyFinalRules(DVRulesEngine.java:338)

at com.intervera.util.DataVera.runAll(DataVera.java:624)

at com.intervera.util.DataVera.run(DataVera.java:709)

at com.intervera.util.DVPoolThread.run(DVPoolThread.java:88)

 

Caused by: java.lang.IllegalArgumentException: Can't add attribute to 0-length text

at java.text.AttributedString.addAttributes(AttributedString.java:342)

at net.sf.jasperreports.engine.util.JRStyledText.getAttributedString(JRStyledText.java:149)

at net.sf.jasperreports.engine.fill.JRFillTextField$2.chop(JRFillTextField.java:695)

at net.sf.jasperreports.engine.fill.JRFillTextField.copy(JRFillTextField.java:654)

at net.sf.jasperreports.engine.fill.JRFillTextField.fill JRFillTextField.java:637)

at net.sf.jasperreports.engine.fill.JRFillBand.fillElements(JRFillBand.java:756)

at net.sf.jasperreports.engine.fill.JRFillBand.fill(JRFillBand.java:487)

at net.sf.jasperreports.engine.fill.JRFillBand.fill(JRFillBand.java:447)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:1321)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:654)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:278)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:186)

at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:558)

at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:160)

at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:353)

at com.intervera.ui.util.DVStaticJasperDesigner.compileReport(DVStaticJasperDesigner.java:75)

at com.intervera.format.DVAbstractJasperFormatter.format(DVAbstractJasperFormatter.java:95)

... 8 more

 

 

 

 

 

 

By: thejstroker - thejstroker

RE: illegalArgumentException when filling report

2005-03-11 12:48

Not sure what the exact cause is, but I solved this by removing and re-adding text fields that had a location value on the margin (IE: x = 0 or y= 0 ) and the problem is solved. I can only guess that it had something to do with the textfields being out or almost out of the printable area?

 

 

 

 

By: Teodor Danciu - teodord

RE: illegalArgumentException when filling rep

2005-04-14 09:13

 

Hi,

 

This is caused by styled text fields containing empty strings.

 

The bug was posted here

 

https://sourceforge.net/tracker/index.php?func=detail&aid=1182184&group_id=36382&atid=416703

 

and it is now fixed in the CVS

version.

 

Thank you,

Teodor

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...