We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Annotations added are not visible when the file is opened

Thread ID:

Created:

Updated:

Platform:

Replies:

124175 May 23,2016 06:07 AM May 24,2016 01:29 AM Xamarin.Forms 1
loading
Tags: PDF
Constantinos
Asked On May 23, 2016 06:07 AM

Hello all,

I have added some annotations to a PDF file. When I navigate in the documents folder where the PDF is stored on the device and open it on my computer, I can see the annotations fine. However, when I view the exact same PDF file using the CustomWebView as described by Xamarin (Display a Local PDF File in a WebView) the annotations cannot be found on the PDF anymore. Is that an issue with how the PDF is rendered using the HTML5 canvas element by Xamarin or do I need to do all the work and somehow pull the annotations and somehow render them on the file by using their Location property?

Thanks,
Costas

Praveenkumar H [Syncfusion]
Replied On May 24, 2016 01:29 AM

Hi Costas, 

Thank you for using syncfusion products, 

At default the custom web view doesn’t have support to display PDF with annotation so we are suggesting you to flatten the annotation before display it in web view, please refer the below code snippet to flatten the annotation 

PdfLoadedDocument doc = new PdfLoadedDocument(); 
 
doc.Pages[0].Annotations[0].Flatten = true; 
 
Please try the above code snippet in your side and let us know the result. 

With Regards, 
Praveen 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;