Adding a masking mask to the chart label in JasperReport

0

I have chart of rows and on the X axis it displays a series of dates. What I want to do is display date in the following pattern: dd/MM/yyyy because it is displayed in the format: yyyy-MM-dd . Submissions?

    
asked by anonymous 15.07.2015 / 20:56

1 answer

3

Direct by Jasper add in the property of your label:

new java.text.SimpleDateFormat("dd/MM/yyyy").format($F{sua data})

Via Java:

SimpleDateFormat formatter = new SimpleDateFormat("dd/MM/yyyy");

String dataFormatada = null;

dataFormatada = formatter.format("sua data hora");
    
15.07.2015 / 21:06