G
Greg Lovern
If I add a watermark to a document in Word 2010, the watermark works
fine and prints fine but if I go into Page Layout | Page Background |
Watermark | Custom Watermark, which displays the "Printed Watermark"
dialog, the dialog says "No Watermark".
Is there a way to add a watermark in VBA that will get that dialog to
indicate that a watermark is in place?
Sub AddTheWatermark()
ActiveDocument.Sections(1).Range.Select
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
Selection.HeaderFooter.Shapes.AddTextEff… _
PowerPlusWaterMarkObject, "DRAFT", "Arial", 1, False, False, 0, 0 _
).Select
With Selection.ShapeRange
..TextEffect.NormalizedHeight = False
..Line.Visible = False
..Fill.Visible = True
..Fill.Solid
..Fill.ForeColor.RGB = RGB(192, 192, 192)
..Fill.Transparency = 0.5
..Rotation = 315
..LockAspectRatio = True
..Height = CentimetersToPoints(6.41)
..Width = CentimetersToPoints(16.03)
..WrapFormat.AllowOverlap = True
..WrapFormat.Side = wdWrapNone
..WrapFormat.Type = 3
..RelativeHorizontalPosition = _
wdRelativeVerticalPositionMargin
..RelativeVerticalPosition = _
wdRelativeVerticalPositionMargin
..Left = wdShapeCenter
..Top = wdShapeCenter
End With
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
End Sub
fine and prints fine but if I go into Page Layout | Page Background |
Watermark | Custom Watermark, which displays the "Printed Watermark"
dialog, the dialog says "No Watermark".
Is there a way to add a watermark in VBA that will get that dialog to
indicate that a watermark is in place?
Sub AddTheWatermark()
ActiveDocument.Sections(1).Range.Select
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
Selection.HeaderFooter.Shapes.AddTextEff… _
PowerPlusWaterMarkObject, "DRAFT", "Arial", 1, False, False, 0, 0 _
).Select
With Selection.ShapeRange
..TextEffect.NormalizedHeight = False
..Line.Visible = False
..Fill.Visible = True
..Fill.Solid
..Fill.ForeColor.RGB = RGB(192, 192, 192)
..Fill.Transparency = 0.5
..Rotation = 315
..LockAspectRatio = True
..Height = CentimetersToPoints(6.41)
..Width = CentimetersToPoints(16.03)
..WrapFormat.AllowOverlap = True
..WrapFormat.Side = wdWrapNone
..WrapFormat.Type = 3
..RelativeHorizontalPosition = _
wdRelativeVerticalPositionMargin
..RelativeVerticalPosition = _
wdRelativeVerticalPositionMargin
..Left = wdShapeCenter
..Top = wdShapeCenter
End With
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
End Sub