![]() |
|
#1
|
|||
|
|||
|
Hi all,
First of, I'm not a VB/VBA programmer, I'm a sas programmer, so please forgive me if say something stupid. I wrote a simple macro in Word 2003 to remove all tables from a document. Code:
Sub Deltables()
Application.ScreenUpdating = False
Dim Tbl As Table
With ActiveDocument
For Each Tbl In .Tables
Tbl.delete
Next Tbl
End With
Application.ScreenUpdating = True
End Sub
Since the tables have different numbers of rows is there a way to do something like... If not tbl.last.row then delete Thanks in advance.. Last edited by macropod; 09-11-2012 at 04:26 PM. Reason: Added code tags & formatting |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Macro to delete all empty rows from all tables
|
braddgood | Word VBA | 15 | 10-02-2015 01:54 PM |
Macro to conditionally delete rows
|
Steve_D | Excel | 2 | 08-24-2012 09:37 PM |
Macro to delete rows with all empty cells
|
ubns | Excel Programming | 2 | 08-14-2012 02:01 AM |
merging rows and creating sub-rows
|
gib65 | Excel | 2 | 12-09-2011 02:09 PM |
| delete email message via blackberry and have it delete on my pop3 and my outlook | Iamthestorm | Outlook | 2 | 10-28-2010 12:21 AM |