VBA 实现word 中加水印并保护起来,不允许做复制粘贴

   ActiveDocument.Sections(1).Range.Select
    ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
    Selection.HeaderFooter.Shapes.AddTextEffect( _
        PowerPlusWaterMarkObject31702585, "我是小蝌蚪", "宋体", 1, False, False, 0, 0). _
        Select
    Selection.ShapeRange.Name = "PowerPlusWaterMarkObject31702585"
    Selection.ShapeRange.TextEffect.NormalizedHeight = False
    Selection.ShapeRange.Line.Visible = False
    Selection.ShapeRange.Fill.Visible = True
    Selection.ShapeRange.Fill.Solid
    Selection.ShapeRange.Fill.ForeColor.RGB = RGB(192, 192, 192)
    Selection.ShapeRange.Fill.Transparency = 0.5
    Selection.ShapeRange.Rotation = 315
    Selection.ShapeRange.LockAspectRatio = True
    Selection.ShapeRange.Height = CentimetersToPoints(3.44)
    Selection.ShapeRange.Width = CentimetersToPoints(17.21)
    Selection.ShapeRange.WrapFormat.AllowOverlap = True
    Selection.ShapeRange.WrapFormat.Side = wdWrapNone
    Selection.ShapeRange.WrapFormat.Type = 3
    Selection.ShapeRange.RelativeHorizontalPosition = _
        wdRelativeVerticalPositionMargin
    Selection.ShapeRange.RelativeVerticalPosition = _
        wdRelativeVerticalPositionMargin
    Selection.ShapeRange.Left = wdShapeCenter
    Selection.ShapeRange.Top = wdShapeCenter
    ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument



   Selection.Editors.Add wdEditorEveryone
    ActiveDocument.Protect Password:="ljc", NoReset:=False, Type:=wdAllowOnlyFormFields, UseIRM:=False, EnforceStyleLock:=False

你可能感兴趣的:(VBA 实现word 中加水印并保护起来,不允许做复制粘贴)