I’m using jaspersoft’s iReport and I want to turn the new java.util.Date() (which is the current date) into 1 month prior from that date. What do I write in the text field expression to achieve this?
I’m using jaspersoft’s iReport and I want to turn the new java.util.Date() (which is
Share
You can use Joda-Time Java API. Call the
minusMonthsmethod on aDateTimeobject.The jrxml file sample:
The result will be:
Note:
Don’t forget to add Joda-Time library to classpath (in my case I’ve add library to the iReport‘s classpath).