There's a discussion at the JasperForge forums on the topic, this is probably the most relevant part:
First drag and drop the field that you want to have dyanamic color twice. Change background color for first field to Yellow and the second field to Red. Now right click Yellow field, click Properties, select Common tab and write this code in the 'Print when expression' box: (make sure to replace myconditionalfield with your actual field name) $F{MyConditinalField}.intValue()>= 5 && $F{MyConditinalField}.intValue()<10?Boolean.TRUE:Boolean.FALSE //if >=5 and <10 then show Yellow field //Code for Red field at the same place just like above $F{MyConditinalField}.intValue()>= 10?Boolean.TRUE:Boolean.FALSE Hope this helps.
It's not exactly what you need, but might likely be close enough to push you in the right direction.