Home › Forums › WinForms controls › Xceed Chart for WinForms › How to change a bubble color after it has been added to a BubbleSeries?
We can contol a bubble color by setting FillEffect when adding a new buble to bubbleSeries. Is there a way to change a bubble’s color after it has been added to a bubbleSeries?
Thank you a lot,
Imported from legacy forums. Posted by Jerry (had 1693 views)
Yes you can do this by using the FillEffects collection on the bubble series :
e.g. : ( (
FillEffect )bubble.Appearance.FillEffects[ 1 ] ).SetSolidColor( Color.DeepSkyBlue );
Note that this collection is filled only if you provide a FillEffect when adding a new DataPoint.
e.g. : bubble.AddBubble( 5, 1, 5.0f, “some label”, new FillEffect( Color.Beige ) );
If you do not, it will be empty, so that you will need to add FillEffect to the collection if you want to change the color of a bubble.
e.g. : bubble.Appearance.FillEffects.Add(
new FillEffect( Color.DeepSkyBlue ) );
You will need to do this for all the DataPoints.
Imported from legacy forums. Posted by André (had 273 views)
It works! Thank you very much for quick reply!
Imported from legacy forums. Posted by Jerry (had 1672 views)