LEGEND COLORS IN BAR CHART

n_srikanth4
n_srikanth4 used Ask the Experts™
on
Hi Experts,

  I have a Bar chart with the column "Issue Ratings" (with values Rating 1,Rating 2,Rating 3,Rating 4, Not Rated) and I want to display different colors for each rating(say "Yellow Green" for Rating 1, "Yellow" for Rating 2, " Orange" for Rating 3, "Red" for Rating 4 and "Gray" for Not Rated).

Could you please walk me through steps of how to achieve this??


Regards,

Sreekanth.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Commented:
If you have the Issue Ratings in the series of the graph, then you can right click on one of the graphs columns and select Series Properties. Go to Fill and then enter the code below into the Color Expression box (fx)
Take a look at the pic below and let me know if this is how the outcome should look:
If the graph below is not correct, then provide a little bit of example data and we'll see if we can come up with the correct way.

=Iif(Fields!IssueRating.Value = "Rating 1","YellowGreen"
	,Iif(Fields!IssueRating.Value = "Rating 2","Yellow"
		,Iif(Fields!IssueRating.Value = "Rating 3","Orange"
			,Iif(Fields!IssueRating.Value = "Rating 4","Red"
				,Iif(Fields!IssueRating.Value = "Not Rated","Gray"
			, "White")))))

Open in new window

GraphColors.JPG

Author

Commented:
Excellent

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial