标签:false cti open ocx cut word文档 ace ati 内容
Sub 批量替换WORD内容()
Dim wd As New Word.Application
pa = ThisWorkbook.Path & "\111.docx"
With wd
.Documents.Open pa
.Visible = False
For i = 2 To Cells(65535, 1).End(xlUp).Row
.ActiveDocument.Content.Find.Execute findtext:=Cells(i, 1), replacewith:=Cells(i, 2), Replace:=wdReplaceAll, Forward:=True
Next
.Documents.Save
.Quit
End With
Set wd = Nothing
End Sub
标签:false cti open ocx cut word文档 ace ati 内容
原文地址:https://www.cnblogs.com/lizicheng/p/9095502.html