Thread: [Solved] Converting tables to text
View Single Post
 
Old 07-29-2024, 12:52 AM
Guessed's Avatar
Guessed Guessed is offline Windows 10 Office 2016
Expert
 
Join Date: Mar 2010
Location: Canberra/Melbourne Australia
Posts: 4,164
Guessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant futureGuessed has a brilliant future
Default

You could try this bodgy code
Code:
Sub TableDeconstructor()
  Dim i As Integer, aRng As Range
  For i = ActiveDocument.Tables.Count To 1 Step -1
    With ActiveDocument.Tables(i)
      If .Columns.Count > 1 Then
        .Columns(2).Select
        Selection.Cut
        Set aRng = .Range
        aRng.Collapse Direction:=wdCollapseEnd
        aRng.Select
        Selection.Paste
        .ConvertToText
      End If
    End With
  Next i
End Sub
__________________
Andrew Lockton
Chrysalis Design, Melbourne Australia
Reply With Quote