Sub AcronymTableToList()
'
' AcronymTableToList Macro
'
'
' Delete column 2 from the first table
Selection.Tables(1).Columns(2).Delete
' Select a column (assuming it's still needed)
Selection.SelectColumn
Selection.Copy
Selection.PasteAndFormat (wdPasteDefault)
' Select the first table
Selection.Tables(1).Select
' Convert rows to text, separating by tabs
Selection.Rows.ConvertToText Separator:=wdSeparateByTabs, NestedTables:=True
' Find and replace paragraph marks with "; "
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^p"
.Replacement.Text = "; "
.Forward = True
.Wrap = wdFindAsk
.Format = False
.MatchCase = True
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
' Find and replace tabs with ", "
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^t"
.Replacement.Text = ", "
.Forward = True
.Wrap = wdFindAsk
.Format = False
.MatchCase = True
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
'
' AcronymTableToList Macro
'
'
' Delete column 2 from the first table
Selection.Tables(1).Columns(2).Delete
' Select a column (assuming it's still needed)
Selection.SelectColumn
Selection.Copy
Selection.PasteAndFormat (wdPasteDefault)
' Select the first table
Selection.Tables(1).Select
' Convert rows to text, separating by tabs
Selection.Rows.ConvertToText Separator:=wdSeparateByTabs, NestedTables:=True
' Find and replace paragraph marks with "; "
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^p"
.Replacement.Text = "; "
.Forward = True
.Wrap = wdFindAsk
.Format = False
.MatchCase = True
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
' Find and replace tabs with ", "
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = "^t"
.Replacement.Text = ", "
.Forward = True
.Wrap = wdFindAsk
.Format = False
.MatchCase = True
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub