ModifyAnnotations

PdfAnnotationEditor.ModifyAnnotations method

Modifica las anotaciones del tipo especificado en el rango de página especificado. Admite modificar las propiedades de la siguiente anotación: Modificado, Título, Contenido, Color, Asunto y Abierto.

public void ModifyAnnotations(int start, int end, Annotation annotation)
ParámetroEscribeDescripción
startInt32El número de la página de inicio.
endInt32El número de página final.
annotationAnnotationEl objeto de anotación contiene nuevas propiedades.

Ejemplos

PdfAnnotationEditor editor = new PdfAnnotationEditor();
editor.BindPdf("example.pdf");
TextAnnotation annot = new TextAnnotation();
annot.Modified = DateTime.Now;
annot.Title = "NEW AUTHOR";
annot.Contents = "NEW CONTENTS";
annot.Color = Color.Red;
annot.Subject = "NEW SUBJECT";
annot.Open = true;
editor.ModifyAnnotations(1, 2, annot);
editor.Save("example_out.pdf");

Ver también