I am using Q1 2013 (before the addition of the CategorySeriesItem class, etc.) and am wondering if there is a method equivelant to http://www.telerik.com/help/aspnet-ajax/htmlchart-application-using-multiple-custom-colors.html for my situation.
1 Answer, 1 is accepted
0
Danail Vasilev
Telerik team
answered on 25 Jul 2013, 05:52 PM
Hello Gabriel,
Depending on the RadHtmlChart's implementation you can use the following approaches:
For programmatically created series items you can use the logic from the Using Multiple Custom Colors to Create Charts help article - create a static class that holds the colors, so that it can be iterated over to return the desired color according to their indexes - the index of the series can point to the index of its color.
For a databound chart you can create an additional column in the datasource that will store the colors for the series. Then you can use the ColorField property for each series type, in order to reference this field/column. Such an example is illustrated in this demo.
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.