hussainian Posted April 13, 2010 Share Posted April 13, 2010 Hi!I want to dynamically change the foreColor of a field based upon the value of the field. For example, a field from the query is STATUS. I want that STATUS to be displayed in color RED when its value is 'V' and the forecolor must be Black when the value is 'O'. Please guide me. Can properties expression do this?Thanks.AsadUllah. Link to comment Share on other sites More sharing options...
dnvsrikanth Posted April 13, 2010 Share Posted April 13, 2010 Hi, Use styles for this purpose.Refer to the example given in <JasperReports-version>\demo\samples\styledtext Thanks,DNV Srikanth. Link to comment Share on other sites More sharing options...
Teodor Danciu Posted April 13, 2010 Share Posted April 13, 2010 Hi, Conditional styles are an option as well:Check the /demo/samples/jasper sample to see the order ID in red depending on a condition. I hope this helps.Teodor Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now