text 批量修改 - 增加一个申明-2018-3-1

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了text 批量修改 - 增加一个申明-2018-3-1相关的知识,希望对你有一定的参考价值。

Sub xiugaimobsan()
Dim myrange As Range
Dim MyDialog As FileDialog, vrtSelectedItem As Variant, doc As Document
    Set MyDialog = Application.FileDialog(msoFileDialogFilePicker)
   
    
If MyDialog.Show = -1 Then
    Application.ScreenUpdating = False
    For Each vrtSelectedItem In MyDialog.SelectedItems
       Set doc = Documents.Open(FileName:=vrtSelectedItem, Visible:=True)
      
       With doc
       With selection.Find
        .ClearFormatting
        .Text = "Conflicts of Interest"
        .Font.Bold = True
        .Execute
        If .Found Then
        
            selection.MoveDown unit:=wdParagraph
            selection.MoveLeft unit:=wdCharacter, count:=1
            selection.TypeText Text:="" & Chr(13) & Chr(10) & "Preprints: We offer you the option to make your (not yet peer-reviewed) manuscript available online immediately in preprint format on platform Preprints. For more information, please refer to the instructions at: https://www.preprints.org/instructions_for_authors. Papers undergo a short screening process and are put online in open access format within 24 hours."
             selection.Paragraphs(1).Range.Style = ActiveDocument.Styles("MDPI_6.2_Acknowledgments")
     selection.Paragraphs(1).Range.Font.Size = 9
     selection.Paragraphs(1).Range.Select

Set myrange = selection.Paragraphs(1).Range
myrange.Select
myrange.SetRange Start:=selection.Range.Start, End:=selection.Range.Start + 10
myrange.Font.Bold = -1
     
        End If
    End With
    
       .Close True
    End With
   
    Next
    Application.ScreenUpdating = True
    End If
    
    MsgBox "格式化文档操作设置完毕!", vbInformation
End Sub

以上是关于text 批量修改 - 增加一个申明-2018-3-1的主要内容,如果未能解决你的问题,请参考以下文章

jQuery批量修改Name值,批量增加name后缀,非each(不需要循环)

c#调用存储过程实现批量增加和修改数据

text 批量修改NCBI-18-7-20

SQL替换语句 批量修改增加删除字段内容

sublime text怎么批量修改

VBA批量增加工作表