title: How to get the the source data of all the series of a chart in VBA?
body: <pre><code>With ActiveWorkbook.Sheets(1)
  INSPECT_CHARTS_NUMBER = .ChartObjects.Count
  For c= 1 To .ChartObjects.Count
  Set INSPECT_CHART = .ChartObjects(c).Duplicate
  
  .ChartObjects(c).Chart.SetSourceData Source:=.Range("e4:h4")
  
  Next lngC
  End With
  </code></pre>
  
  <p>I do the above to change the source data of a chart in VBA this line <code>.Chart.SetSourceData Source:=.Range("e4:h4")</code>does do job, but this will not work if there are multiple series in that chart.</p>
  
  <p>How can I get the sourcedata of all the series and then how can I change them separately?</p>