r*********s 发帖数: 60 | 1 Sub Main()
Dim fn(2000) As String
Dim S_find, S_replace As String
fn(1) = "test1.doc"
fn(2) = "test2.doc"
....
Rem 文件名用dir > list.txt 然后处理一下就可以有两千个赋值了
S_find = "字段1"
S_replace = "字段2"
For I = 1 To 2000
Documents.Open FileName:=fn(I), ConfirmConversions:=False, _
ReadOnly:=False, AddToRecentFiles:=False, PasswordDocument:="", _
PasswordTemplate:="", Revert:=False, WritePasswordDocument:="", _
WritePasswordTemplate:="", Format:=wdOpenFormatAuto
Selection.Find.Cl |
|