title: How to mark and recognize back a table via bookmarks
body: <p>I am trying to insert tables marked with a Name via a bookmark so I can later recognize them again. </p>
  
  <p>Below I have added my source code in question. At pos3 I created a table with 2 rows and add a bookmark for its range. But when repeating the Sub I always end up in the case of pos1 .. my bookmark is not found in the table selection. (trying to reach pos2)</p>
  
  <p>The bookmark itself is added, but maybe not to the table. I suspect the error to be there. </p>
  
  <p>I can see the bookmark in the bookmark-list of Word. But if I do a manual "go to" the cursor seems to end up off screen somewhere, so I suspect its not added correctly to the table range. </p>
  
  <pre><code>Private Sub PrepareFooter()
  Dim oSection As Section
  Dim oFooter As HeaderFooter
  Dim oRng As Range
  Dim tbl As Table
  Dim cell As cell
  Dim foundFooterTable As Boolean
  For Each oSection In ActiveDocument.Sections
      For Each oFooter In oSection.Footers
          With oFooter.Range
              For Each tbl In .Tables
                  tbl.Select
                  If Selection.Bookmarks.Count &lt;&gt; 1 Then
                      tbl.Delete ' &lt;-- pos1
                  ElseIf Selection.Bookmarks(1).Name &lt;&gt; "FooterTable" Then
                      tbl.Delete
                  Else
                      foundFooterTable = True ' &lt;-- pos2
                      FormatFooterTable tbl 
                  End If
              Next
          End With
          oFooter.Range.Select
          Selection.Collapse wdCollapseStart
          If Not foundFooterTable Then
              Set tbl = ActiveDocument.Tables.Add(Selection.Range, 2, 1)
              tbl.Select
              ActiveDocument.Bookmarks.Add Range:=Selection.Range
  , Name:="FooterTable" ' &lt;- pos3
              FormatFooterTable tbl
          End If
      Next oFooter
  Next oSection
  End Sub
  </code></pre>
  
  <p>thanks for any ideas about what I might do wrong!</p>