Skip to content

# PDFReplaceImageEventArgs

Namespace: O2S.Components.PDF4NET.Transforms

Defines the arguments for PDFReplaceImageTransform.ReplaceImage event.

    public class PDFReplaceImageEventArgs : System.EventArgs

Inheritance Object → EventArgs → PDFReplaceImageEventArgs

## Properties

### NewImage

Gets or sets the image that will replace the old image.

    public PDFImage NewImage { get; set; }

Property Value

PDFImage
The replacement image.

Remarks

If this property is set to null, the image will be removed from the page.

### NewImageID

Gets or sets the ID of the new image.

    public PDFCosName NewImageID { get; set; }

Property Value

PDFCosName
The ID used to reference the image in the page content.

Remarks

This ID identifies the image in the Resources dictionary and it is also used as parameter for the Do operator.

### OldImage

Gets the image that will be replaced.

    public PDFVisualImage OldImage { get; }

Property Value

PDFVisualImage
The image that will be replaced.

Remarks

This property has a value if PDFReplaceImageTransform.DecodeOldImage property has been set to true

### OldImageID

Gets the ID of the old image.

    public PDFCosName OldImageID { get; }

Property Value

PDFCosName
The ID used to reference the image in the page content.

Remarks

This ID identifies the image in the Resources dictionary and it is also used as parameter for the Do operator.