title: changing range of source data for a chart in Powerpoint
body: <p>I have a powerpoint template with a simple bar chart with (say) 15 rows</p>
  <p>Depending of the results of a data lookup occurring in the c# application, using NetOffice Interop I may need to reduce the number of rows that are being displayed</p>
  <p>I had hoped that SetSourceData would allow me to override the current selection but</p>
  <pre><code>Shape sh = slide.Shapes['mychart'];
  NetOffice.PowerPointApi.Chart cx = sh.Chart;
  cx.SetSourceData(&quot;='Sheet1'!$A$1:$B$5&quot;);
  </code></pre>
  <p>seems to be ignored, and the source range remains the full underlying data</p>
  <p>(not critical to keep the underlying data, so if there's a way to solve the problem by truncating rows happy to do that)</p>