usmanazizgroupdocs
4/17/2017 - 9:56 AM

Documents-AddTextWatermarkIntoHeaderFooter.vb

' For complete examples and data files, please go to https://github.com/groupdocs-watermark/GroupDocs.Watermark-for-.NET
Using doc As CellsDocument = Document.Load(Of CellsDocument)(Utilities.MapSourceFilePath(FilePath))
    Dim watermark As New TextWatermark(WatermarkText, New Font("Segoe UI", 19, FontStyle.Bold))
    watermark.ForegroundColor = Color.Red
    watermark.BackgroundColor = Color.Aqua
    watermark.VerticalAlignment = VerticalAlignment.Top
    watermark.HorizontalAlignment = HorizontalAlignment.Center
    doc.Worksheets(0).AddWatermarkIntoHeaderFooter(watermark)
    doc.Save()
End Using