Sub TextBoxCleaner()
'Send cursor to start of main body text
Selection.HomeKey Unit:=wdStory
'start cycling through each text box
For Each oStory In ActiveDocument.Shapes
'Check if text box contains text
With oStory.TextFrame
If .HasText Then
'if it does, put the cursor at the start of the text in the box
Set myRange = .TextRange
myRange.Select
Selection.Collapse Direction:=wdCollapseStart
End If
End With
'Now that we are inside the text box, run the TRADOS Cleanup macro
Application.Run ("TemplateProject.tw4winClean.Main")
'Go to the next text box
Next oStory
End Sub
Launch MS Word and in the VB Editor, add the macro code above.
Now open the file in Word and run the TextBoxCleaner macro to clean all segmented text from any text boxes within your document.