要先设置是不太可能的,可以先输入内容,完成后用宏一次性全部处理即可。参考如下宏代码:Sub Qxhh()
With ActiveDocument.Content.Find
.ClearFormatting
.Replacement.ClearFormatting
.Execute findtext:="[^11^13]{1,}", replacewith:="^p", _
MatchWildcards:=True, Replace:=wdReplaceAll
End With
Selection.HomeKey wdStory
Selection.EndKey wdLine
Do While Selection.Range.End <> ActiveDocument.Content.End - 1
If Not Range(Selection.Range.End, Selection.Range.End + 1) Like vbCr Then
Selection.TypeParagraph
Selection.TypeParagraph
Else
Selection.TypeParagraph
Selection.MoveRight
End If
Selection.EndKey wdLine
Loop
End Sub
温馨提示:答案为网友推荐,仅供参考