View Single Post
 
Old 05-04-2015, 03:05 AM
Catty Catty is offline Windows 7 32bit Office 2010 32bit
Advanced Beginner
 
Join Date: Nov 2013
Posts: 39
Catty is on a distinguished road
Default

Thank you all for your responses.

I was eventually able to get the macro to do what I wanted, albeit I think I took the long route to do it.

Below is what I used, but will definitely use your suggestions in the future...thanks again



Code:
Dim oTable As Table
Dim oCell As Cell
Dim oNewRow As Row

    'Go to InsertBookmark
        Selection.GoTo what:=wdGoToBookmark, Name:="InsertBookmark"
        
    'Insert table near bookmark
    ActiveDocument.Tables.Add Range:=Selection.Range, NumRows:=1, NumColumns:=1
    
    'identify table
    Set oTable = ActiveDocument.Tables(1)
    ' Insert new row
    Set oNewRow = oTable.Rows.Item(1)
    'identify the required cell in the new row
    Set oCell = oNewRow.Cells(1)        'the first cell in the row
   
    'insert/do whatever in the cell.....
Reply With Quote