pdf linking for images

I am able to export an image to a pdf successfully but my requirement is the image is a flow chart
when some one in the pdf clicks a box in the image they should be taken in different pages in same pdf.For example the linking in html,i want to implement the same in pdf
Any inputs are highly appriciated


1 Reply

SS Sri Subhashini M Syncfusion Team June 3, 2008 05:06 AM UTC

Hi Sattar,

Thanks for using Syncfusion product.

We can navigates to specified destination within the document by using DocumentLinkAnnotation.

Kindly use the below code to add annotations,

// Drawing Annotation
RectangleF docLinkAnnotationRectangle = new RectangleF(110, 130, 93, 65);
PdfDocumentLinkAnnotation documentAnnotation = new PdfDocumentLinkAnnotation(docLinkAnnotationRectangle);
documentAnnotation.Text = "Document link annotation";
documentAnnotation.Color = new PdfColor(Color.Navy);
documentAnnotation.Border.Width = 3;
documentAnnotation.Border.HorizontalRadius = 25;
documentAnnotation.AnnotationFlags = PdfAnnotationFlags.NoRotate;
PdfPage page2 = document.Pages.Add();
documentAnnotation.Destination = new PdfDestination(page2);
documentAnnotation.Destination.Location = new Point(10, 0);
page.Annotations.Add(documentAnnotation);
page.Graphics.DrawString("Click on the rectangle to move to next page", font, PdfBrushes.Black, new PointF(100, 240));

Please look into the sample which is available in the below specified location and let me know if this helps.

http://websamples.syncfusion.com/samples/Pdf.Windows/F74131/main.htm

Regards,
Suba



Loader.
Up arrow icon