View Single Post
 
Old 08-17-2018, 05:49 AM
macropod's Avatar
macropod macropod is online now Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Your approach will insert unnecessary tabs before the line breaks - and in some situations that could affect the overall layout.

For a macro, try:
Code:
Sub Demo()
Application.ScreenUpdating = False
With ActiveDocument.Range
  With .Find
    .ClearFormatting
    .Replacement.ClearFormatting
    .Forward = True
    .Wrap = wdFindContinue
    .Text = "^g^g^g"
    .Replacement.Text = "^&^l^l"
    .Execute Replace:=wdReplaceAll
    .Text = "^g^l"
    .Replacement.Text = "^t^&"
    .Execute Replace:=wdReplaceAll
    .Text = "^g^t"
    .Replacement.Text = "^t^&"
    .Execute Replace:=wdReplaceAll
  End With
End With
Application.ScreenUpdating = True
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote