我正在尝试获取参考数据以绘制在图表上。现在,我得到了代码:
notifyMe()
我希望我可以使用写有“ D”的变量。我该怎么办?
Txs
答案 0 :(得分:0)
如下:
Dim letter As String
letter = "D"
ActiveSheet.ChartObjects("PyramidPlanned").Activate
ActiveChart.PlotArea.Select
Application.CutCopyMode = False
ActiveChart.FullSeriesCollection(1).Name = "='HC Planned'!$" & letter & "$2"
ActiveChart.FullSeriesCollection(1).Values = "='HC Planned'!$" & letter & "$461:$" & letter & "$469"