
01-23-2015, 10:57 AM
|
Novice
|
|
Join Date: Jan 2015
Posts: 3
|
|
Fantastic Answer
Quote:
Originally Posted by gmayor
Indeed it does, which is what I took your request to mean. However if you want every other table removed then using the similar syntax:
|
Aha it's okay , anyway , Thank you for trying to lend a hand
Quote:
Originally Posted by gmayor
Code:
Sub Removetables()
Dim oTable As Table
Dim i As Integer
i = 1
For Each oTable In ActiveDocument.Tables
If i Mod 2 = 1 Then oTable.Delete
i = i + 1
Next oTable
End Sub
This will remove table 1, table 3, table 5 etc
If you want to remove table 2, table 4, table 6 etc then change
|
Quote:
Originally Posted by gmayor
Code:
If i Mod 2 = 1 Then oTable.Delete
to
Code:
If i Mod 2 = 0 Then oTable.Delete
|
Yes , this one more helpful then delete odd tables , and thank you for explain both of methods which improve my skills
I Appreciating your consideration and cooperation
|