Change color based on field value in Jaspersoft Studio

Change color based on field value in Jaspersoft Studio

We may change the color, font size and style of the field value based on a condition.

For example, we have two fields called $F{numberofissues} and $F{projectname}. We want to highlight $F{projectname} by styling it with red color, font size 16 and bold style if the number of issue is greater or equal than 30.

1. Create a style

a6vgvbt

2. Under the style you created, create Conditional Style and enter the condition as expression:

$F{numberofissues} >=30

ds07myf

3. Select $F{projectname} field on the design area and choose the style you created on the properties.

g0eaggz

This is all. When you run your report, the names of the projects will be styled based on number of issues.

 

 

 

 

Advertisements

#ireport, #jaspersoft-studio, #jasperstudio