Sets the watermark settings in the current document.
Name | Type | Description |
Settings | ApiWatermarkSettings | The object which represents the watermark settings. |
builder.CreateFile("docx"); var oDocument = Api.GetDocument(); var oParagraph = oDocument.GetElement(0); oParagraph.AddText("A watermark was inserted into this document."); oDocument.InsertWatermark("Watermark", true); var oSettings = oDocument.GetWatermarkSettings(); oSettings.SetText("ONLYOFFICE"); oDocument.SetWatermarkSettings(oSettings); builder.SaveFile("docx", "SetWatermarkSettings.docx"); builder.CloseFile();