WebImage.AddImageWatermark Method (String, Int32, Int32, String, String, Int32, Int32)

Adds a watermark image using a path to the watermark image.

Namespace:  System.Web.Helpers
Assembly:  System.Web.Helpers (in System.Web.Helpers.dll)

'Declaration
Public Function AddImageWatermark ( _
	watermarkImageFilePath As String, _
	width As Integer, _
	height As Integer, _
	horizontalAlign As String, _
	verticalAlign As String, _
	opacity As Integer, _
	padding As Integer _
) As WebImage
'Usage
Dim instance As WebImage
Dim watermarkImageFilePath As String
Dim width As Integer
Dim height As Integer
Dim horizontalAlign As String
Dim verticalAlign As String
Dim opacity As Integer
Dim padding As Integer
Dim returnValue As WebImage

returnValue = instance.AddImageWatermark(watermarkImageFilePath, _
	width, height, horizontalAlign, verticalAlign, _
	opacity, padding)

Parameters

watermarkImageFilePath
Type: System.String
The path of a file that contains the watermark image.
width
Type: System.Int32
The width, in pixels, of the watermark image.
height
Type: System.Int32
The height, in pixels, of the watermark image.
horizontalAlign
Type: System.String
The horizontal alignment for watermark image. Values can be "Left", "Right", or "Center".
verticalAlign
Type: System.String
The vertical alignment for the watermark image. Values can be "Top", "Middle", or "Bottom".
opacity
Type: System.Int32
The opacity for the watermark image, specified as a value between 0 and 100.
padding
Type: System.Int32
The size, in pixels, of the padding around the watermark image.

Return Value

Type: System.Web.Helpers.WebImage
The watermarked image.

  • Medium trust for the immediate caller. This member can be used by partially trusted code.
Show: