|
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件 ★ 免费下载 ★ ★ 使用帮助★
试做了一个,看对不对:根据图表,反向获得图表数据源
Dim Mychart As ChartObject
Dim Myse As Series
Dim k As Integer, i As Integer
Dim ST As String
Dim Mysz
Range("A26:D26") = Array("系列名字", "X坐标数据", "数据引用单元格", "数据次序")
k = 26
For Each Mychart In Sheet1.ChartObjects
k = k + 1
Cells(k, 1) = "图表名称:" & Mychart.Name
For Each Myse In Mychart.Chart.SeriesCollection
k = k + 1
ST = Myse.Formula
ST = Mid(ST, 9, Len(ST) - 9)
Mysz = Split(ST, ",")
Range(Cells(k, 1), Cells(k, UBound(Mysz) + 1)) = Mysz
Next
Next
[ 本帖最后由 jiulongpo 于 2009-4-11 22:16 编辑 ] |
|