|
我用代码创建了一个图形,却有些百分比是重叠到一块了,请教如何避免,用代码.
代码如下:
Sub Macro1()
'
' Macro1 Macro
' 宏由 USER 录制,时间: 2009-5-14
'
'
Range("A1").Select
ActiveCell.FormulaR1C1 = "50"
Range("A2").Select
ActiveCell.FormulaR1C1 = "30"
Range("A3").Select
ActiveCell.FormulaR1C1 = "16"
Range("A4").Select
ActiveCell.FormulaR1C1 = "2"
Range("A5").Select
ActiveCell.FormulaR1C1 = "1"
Range("A6").Select
ActiveCell.FormulaR1C1 = "1"
Range("A1:A6").Select
Charts.Add
ActiveChart.ChartType = xl3DPieExploded
ActiveChart.SetSourceData Source:=Sheets("Sheet1").Range("A1:A6"), PlotBy:= _
xlColumns
ActiveChart.Location Where:=xlLocationAsObject, Name:="Sheet1"
ActiveChart.ApplyDataLabels AutoText:=True, LegendKey:=False, _
HasLeaderLines:=True, ShowSeriesName:=False, ShowCategoryName:=False, _
ShowValue:=True, ShowPercentage:=True, ShowBubbleSize:=False
End Sub |
-
百分比重叠
|