本帖最后由 相见是缘8 于 2019-2-15 06:47 编辑
啊、这样就可以了。感谢前辈多次帮忙!
Sub deleteParagraphs_BeginWith像() Dim doc As Document: Set doc = ActiveDocument With doc.Content.Find .Text = "像" Do While .Execute With .Parent.Paragraphs(1).Range If .Characters(1) = "像" And Len(.Text) < 50Then.Delete End With .Parent.Start =.Parent.Paragraphs(1).Range.End Loop End With EndSub
想再问一下前辈下面这几句代码,标准的中文注释是什么意思?
.Parent.Start = .Parent.Paragraphs(1).Range.End With.Parent.Paragraphs(1).Range If .Characters(1) ="像" And Len(.Text)< 50 Then
|