spen_lang
asked on
VB NET Pie Chart Segment Colours
Hi,
Is it possible to set the colour of each segment of a oie chart in VB NET using the Chart control?
For example I have a pie chart that counts the names in a table, I would like Ted to be red and Fred to be green etc...
I have found out how to do it by index number:
series1.Points(0).Color = Color.Blue
but need something like this
series1.Points("Fred").Col or = Color.Green
series1.Points("Ted").Colo r = Color.Red
Thanks, Greg
Is it possible to set the colour of each segment of a oie chart in VB NET using the Chart control?
For example I have a pie chart that counts the names in a table, I would like Ted to be red and Fred to be green etc...
I have found out how to do it by index number:
series1.Points(0).Color = Color.Blue
but need something like this
series1.Points("Fred").Col
series1.Points("Ted").Colo
Thanks, Greg
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I have provided a working solution using the details you have provided!
ASKER
Thank you
ASKER
I've requested that this question be closed as follows:
Accepted answer: 500 points for Éric Moreau's comment #a40922810
Assisted answer: 0 points for spen_lang's comment #a40922832
for the following reason:
This is what I ended up using.
Accepted answer: 500 points for Éric Moreau's comment #a40922810
Assisted answer: 0 points for spen_lang's comment #a40922832
for the following reason:
This is what I ended up using.
ASKER
The colour is returned within the dataset that is bound to the chart series. I have used...
Open in new window