![]() |
#2
|
||||
|
||||
![]()
The basic code is as follows.
Code:
Sub wiperows() Dim i As Integer With Selection.Tables(1) For i = .Rows.Count To 1 Step -1 If Len(.Rows(i).Cells(1).Range.Text) = 2 Then .Rows(i).Delete Next i End With End Sub - the user hasn't put their cursor in the table before running the macro - there are vertically merged cells which confuses Word when it is looking for a 'row'
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
Tags |
wordvba |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
cltay87 | Word VBA | 4 | 02-27-2017 04:23 AM |
![]() |
braddgood | Word VBA | 15 | 10-02-2015 01:54 PM |
![]() |
Bathroth | Word VBA | 1 | 10-01-2014 01:40 PM |
![]() |
ubns | Excel Programming | 2 | 08-14-2012 02:01 AM |
Temporarily show/hide selected table rows | glricht | Word Tables | 0 | 12-29-2009 05:40 AM |