Jump to content
Changes to the Jaspersoft community edition download ×

Using exporter properties...


desperate

Recommended Posts

Hello community,

can anybody tell me how to use the following exporter properties:

- net.sf.jasperreports.export.xls.detect.cell.type

- net.sf.jasperreports.print.keep.full.text

Detect cell type sounds for me like evaluating field types while exporting and converting their cells accordingly. But it does not seem like that. In my special case, I have a text field collecting float values. If nothing is found (NaN), " -- " is returned. In my excel export, every number is signed as text formatted number, but it is not automatically converted to a numerical type, not even using detect cell type property. What can I do to achieve that?

Keep full text property sounds for me like setting cell height big enough to be able to read complete text inside. But this also does not seem to be like that. Cell height does not change by use of this property. How can this be done for text fields with dynamical height?

I put these two properties one time for whole report and then also separately for every field concerned.

Thank you in advance for your hints!

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Hi,

Regarding the net.sf.jasperreports.export.xls.detect.cell.type property, apparently the problem is the "--" value returned when no data is found. The "--" string is not automatically converted into a numeric value, so you have to manually convert it, using a conditional expression. If you still have problems with that, please post the jrxml here.

Regarding the net.sf.jasperreports.print.keep.full.text property, it is used to preserve the initial text content of a text field in order to be reused, if necessary, at export time. If you just need the textfield to stretch vertically in order to render visible all the text content, then set the attribute isStretchWithOverflow="true" for that textfield. Take a look to the Stretch sample to see how it works.

Hope this helps,

sanda

Link to comment
Share on other sites

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