![]() |
|
#5
|
|||
|
|||
|
Paul,
Thanks a lot! I've managed to solve the puzzle with your help. The code is: Code:
Sub remove_tables()
Application.ScreenUpdating = False
With ActiveDocument.Range
With .Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "([a-z]\))"
.Style = "table-1"
.Replacement.Text = ""
.Format = bSty
.Forward = True
.Wrap = wdFindStop
.MatchCase = True
.MatchWholeWord = True
.MatchWildcards = True
.MatchSoundsLike = False
.MatchAllWordForms = False
.Execute
End With
Do While .Find.Found
If .Information(wdWithInTable) = True Then
.Duplicate.Tables(1).ConvertToText Separator:=vbTab
End If
.Collapse wdCollapseEnd
.Find.Execute
Loop
End With
Exit Sub
errExit:
Beep
Application.ScreenUpdating = True
End Sub
Last edited by macropod; 02-08-2021 at 10:44 PM. Reason: Added code tags |
| Tags |
| find, replace, tables |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Using Find/Replace or VBA | davidku | Word | 4 | 04-27-2012 04:39 PM |
Bad view when using Find and Find & Replace - Word places found string on top line
|
paulkaye | Word | 4 | 12-06-2011 11:05 PM |
Is there a way to use "find/replace" to find italics words?
|
slayda | Word | 3 | 09-14-2011 02:16 PM |
Find and Replace
|
kjxavier | Excel | 3 | 08-12-2011 10:49 PM |
Help with find and replace or query and replace
|
shabbaranks | Excel | 4 | 03-19-2011 08:38 AM |