Before I say any thing, I have to admit, Crystal Reports is the suckiest (I'd to find a unique word) product in my list of sucky products I have ever used. I do not have any words to describe the SUCKER LEVEL for this product. BTW I am using version CR 10.
Any way, in this article let's see how to change the color of a Chart bars based on certain conditions. For example, if the value of the chart is > 100, the color would be green otherwise it would be red.
Let's talk about changing the color of the chart.
- Right-click on the chart and select Chart Expert
- Click on the Options tab. Guess what, if you have default Automatically set chart options selected, you will not see Options tab. So first, clear Automatically set chart options as following:
- Verify that the Color radio button is selected in the Chart Color group. See following figure:
- Click the Format button in the Chart Color group
- The Chart Color Format Expert appears. For each bar that you want to color:
a. Click New to add a new item to the Item List
b. From the Item Editor select the field that you want to check (from the first dropdown list), the condition (from the second dropdown list) and the value to check against (from the third dropdown list).
c. Select the custom color to apply if the conditions set. When you have entered all of the custom colors, click OK
- Preview the report.
Also do not forget the following :
- Right-click on the chart and select Chart Options >> General
- Click the Look tab
- Set the Color Mode drop down list to Color by Groups and click OK.