Jump to content
Changes to the Jaspersoft community edition download ×

how to trim() to remove whitespace?


rajuchacha007

Recommended Posts

Experts,

 

It would be a great help if you please do let me know how to use trim() in the expression so as to remove whitespaces? At present, I am joining two fields using expression, ($F{PROJECT_CODE}+" ("+$P{PROCESS_TYPE}+")"). It's producing some white space in the pdf file affecting the alignment of the report. I thought of trim() method to so as to delete white space? Is it the right way or any method exists? please do let me know. Many thanks in advance.

 

 

Best regards.

Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

wdn is correct.

 

The $F{PROJECT_CODE} field should be thought of as a Java Object, with type being whatever type you've specified in declaring the field (String,Integer, Boolean, etc.).  Just compare the type declared in the Java API and call the appropriate methods you want that way.



Post Edited by robsil at 08/12/2010 19:42
Link to comment
Share on other sites

  • 5 months later...

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