If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed.
I'm trying to change the name of the category name in a pivot chart.
I have pivot table where I summarize some values from a table. I than created a chart out of this pivot table. The chart type is a pie-of-pie chart.
The first pie consists of 2 values "true" and "false". The 2nd pie is a break-down pie of the "true" pie slice.
When the chart is generated, it shows "Others" in the 1st pie. But I want to change this name to "true".
How am I able to do it?
Any help would be appropriated and thanks in advance!
You can however change the text either manually or with code.
Code:
Sub ChangeOthersDataLabel()
Dim lngIndex As Long
Dim strNewText As String
strNewText = "My Label"
With ActiveChart
With .SeriesCollection(1)
.DataLabels(.Points.Count).Text = strNewText
End With
End With
End Sub
Unfortunately I'm not very good in coding.
When I try to manually overwrite "Others" to "true", somehow all the other category names are changing to "true" as well.
Hello Andy Pope.
Thanks for your help!
I found a work-around. When I import the pivot charts to PowerPoint, I can manually overwrite the category names, without changing all the other names as well.