

MemoryStream stream = new MemoryStream () document. Add ( popupAnnotation ) //Save the document into stream. NewParagraph //Adds this annotation to the created page. VerticalRadius = 30 //Sets the pdf popup icon. Text = "Test popup annotation" popupAnnotation. PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation () popupAnnotation. Add () //Creates a rectangle RectangleF rectangle = new RectangleF ( 10, 40, 30, 30 ) //Creates a new popup annotation. PdfDocument document = new PdfDocument () //Creates a new page PdfPage page = document. Close ( true ) //Defining the ContentType for pdf file string contentType = "application/pdf" //Define the file name string fileName = "PopupAnnotation.pdf" //Creates a FileContentResult object by using the file contents, content type, and file name return File ( stream, contentType, fileName ) Position = 0 //Closes the document document. Add ( popupAnnotation ) //Save the document into stream MemoryStream stream = new MemoryStream () document.

PdfPopupAnnotation popupAnnotation = new PdfPopupAnnotation ( rectangle, "Test popup annotation" ) popupAnnotation.

