Gunaseelan
Gunaseelan

Reputation: 15535

Replace the data of AChartEngine's piechart

I am drawing piechart using ACartENgine . And I want to replace the data of piechart. To replace I called mSeries.clear(); method to remove all old data and then add new dataset to mSeries. But my problem is while do this all my legends displayed in white color instead of category color. How can I avoid this problem. All I want is replace the data of piechart with new values. Is there any better idea. How can I achieve this? Any one please help me.

Thanks in advance.

Upvotes: 1

Views: 325

Answers (1)

Dan D.
Dan D.

Reputation: 32391

There is a set(int index, String title, double value) method in the CategorySeries class that you can use.

Just make sure you are using the latest version available here.

Upvotes: 1

Related Questions