Gets or sets the watermark associated with the current page layout.
Namespace:
C1.C1PreviewAssembly: C1.C1Report.2 (in C1.C1Report.2.dll)
Syntax
C# |
---|
[BrowsableAttribute(false)] [DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)] public RenderObject Watermark { get; set; } |
Visual Basic |
---|
<BrowsableAttribute(False)> _ <DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)> _ Public Property Watermark As RenderObject Get Set |
Examples
For example, the following code creates a watermark:
Copy CodeVisual Basic
' Create watermark and layout. Dim waterMark As New RenderImage Dim pl As New C1.C1Preview.PageLayout() ' Set the watermark image. waterMark.Image = Image.FromFile("c:\image.png") waterMark.Y = New Unit(2, UnitTypeEnum.Inch) pl.Watermark = waterMark Me.C1PrintDocument1.PageLayout = pl ' Generate the document. Me.C1PrintDocument1.Generate() |
Copy CodeC#
// Create watermark and layout. RenderImage waterMark = new RenderImage(); C1.C1Preview.PageLayout pl = new C1.C1Preview.PageLayout(); // Set the watermark image. waterMark.Image = Image.FromFile("c:\\image.png"); waterMark.Y = new Unit(2, UnitTypeEnum.Inch); pl.Watermark = waterMark; this.c1PrintDocument1.PageLayout = pl; // Generate the document. this.C1PrintDocument1.Generate(); |