title: Unable to Group some shapes in Powerpoint 2010
body: <p>I am having some difficulty using the <code>.Group</code> method on a <code>ShapeRange</code>.</p>
  
  <p>For example, I am not able to Group a table with a textbox, nor am I able to group the slide's title shape with a textbox, etc.  I notice that Powerpoint does not allow you to Group certain shapes together, as the "Group" option is disabled on the context menu:</p>
  
  <p><img src="https://i.stack.imgur.com/vfViL.png" alt="Group is disabled for some shapes"></p>
  
  <p>I try the following in VBA, which predictably fails:</p>
  
  <pre><code>Sub TestGroupShapes()
  
      Dim sld As slide
      Dim tb As Shape
      Dim tb2 As Shape
      Dim tbl As Shape
  
      Set sld = ActivePresentation.Slides(1)
      Set tbl = sld.Shapes.AddTable(3, 3, 100, 100, 100, 100)
      tbl.Name = "Table"
      Set tb = sld.Shapes.AddTextbox(msoTextOrientationHorizontal, 200, 200, 50, 50)
      tb.Fill.Visible = msoCTrue
      tb.Name = "TextBox1"
      Set tb2 = sld.Shapes.AddTextbox(msoTextOrientationHorizontal, 300, 300, 50, 50)
      tb2.Fill.Visible = msoCTrue
      tb2.Name = "TextBox2"
  
      '## This works. I am able to group two textbox shapes together:
      sld.Shapes.Range(Array(tb2.Name, tb.Name)).Group
  
      '## This fails, I am not able to group a shape with a Table
      '   Also fails, e.g., if I try to group with the slide's Title shape, etc.
      sld.Shapes.Range(Array(tbl.Name, tb.Name)).Group
  
  
  End Sub
  </code></pre>
  
  <p><strong>Are there any other methods I might use to "tie" certain shapes together?</strong> </p>
  
  <p><strong>Update 5/25/2013</strong></p>
  
  <p>The problem is that shapes which a user might copy (Ctrl+V/etc) retain the same <code>.Name</code> as the original shape. The application I am developing assigns unique IDs to shapes that it creates, but these IDs will not remain unique if the user copies them. For example, some user might "copy" an existing textbox, instead of inserting a <em>new</em> textbox.</p>
  
  <p>Since the application is required to maintain and update the shapes (tables, textboxes, charts, etc), any shape(s) created by "copying" an existing shape can potentially cause problems, since my application will no longer be able to determine which shapes to update, remove, etc.</p>
  
  <p>What I was hoping to do is <code>Group</code> them together. Although it's not failsafe (the user could still manually <code>Ungroup</code> them, but I felt like that would be at least an additional safegaurd.</p>