[英]How to change the subtype of Chart from VBA code
我觉得你必须改变。ChartTyp
例如:
ActiveChart.ChartType = 52
这是正确值列表https://bettersolutions.com/excel/charts/vba-chart-types.htm
如果要切换 x 轴和 y 轴数据,请尝试以下方法之一:
ActiveChart.PlotBy = xlColumns
ActiveChart.PlotBy = xlRows
我希望我有所帮助:)
它们看起来都像堆叠的柱子。 VBA 没有图表子类型,并使用以下语法控制图表类型:
ActiveChart.ChartType = xlColumnClustered
ActiveChart.ChartType = xlColumnStacked
ActiveChart.ChartType = xlColumnClusteredStacked100
VBA 的 Object 浏览器向您展示了所有可能性。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.