title: Get shape index in powerpoint VBA
body: <p>I hope this is a super simple question but for some reason i cant figure it out.</p>
  
  <p>I need to delete a subset of the selected shapes on a powerpoint slide using VBA. I can do this using:</p>
  
  <pre><code>ActivePresentation.Slides(1).Shapes.Range(_Index_).Delete
  </code></pre>
  
  <p>Where _Index_ is either an array of shape indexes (integers) or shape names (stings).</p>
  
  <p>Since the shape names are not unique (and people i am making this macro for have a nasty habit of having multiple shapes with the same name) i need to rely on the shape index number. My problem is i dont know how to get the index number of a given shape.</p>
  
  <p>I can only see how i get the shape name or shape ID using:</p>
  
  <pre><code>ActiveWindow.Selection.ShapeRange(IdNum).Name
  ActiveWindow.Selection.ShapeRange(IdNum).ID
  </code></pre>
  
  <p>So my question is: How do i get the shape index of selected shapes?</p>