View Single Post
 
Old 04-20-2017, 09:49 AM
Tye30 Tye30 is offline Windows 7 32bit Office 2010 32bit
Novice
 
Join Date: Apr 2017
Posts: 7
Tye30 is on a distinguished road
Thumbs up

macropod, thank you! This is great! I just had to tweak it a little bit, but this what I was hoping for

Code:
 
    Dim StrTmp As String
    
    With Selection
        .Start = .Paragraphs.First.Range.Start
        .End = .Paragraphs.First.Range.End - 1
         StrTmp = Trim(Replace(Replace(.Text, "L31", "@@@"), "|", ""))
        'Do While InStr(StrTmp, "  ") > 0
        ' StrTmp = Replace(StrTmp, "  ", " ")
        'Loop
        .Text = StrTmp
    End With
    Selection.MoveDown Unit:=wdLine, Count:=1
    Selection.HomeKey Unit:=wdLine
Reply With Quote