PDF Reviewer in C # (ASP.NET/Silverlight?)

I essentially plan to mimic the comment features in PDFs, but on the Internet. I.e; the user should be able to register and upload a PDF file, and then many different users should be able to add comments, etc. to the same file (and view the comment file on the Internet).

  • External libraries are fine. Free is clearly preferable, but commercial is good if they provide a lot of the necessary functionality.

  • Comments do not have to be exported from the site. That is, if the comments are simply placed as a layer on top of the PDF file (and not in the actual file), which is approved. But obviously, the greater the export functionality, the better.

I looked through several libraries (using related questions and google), and while I find some that seem to do what I want, I am not sure if they are bee knees plus I would like to do as much as possible.

Three main approaches that I thought of:

  • Use some kind of PDF view of your own, and then just delete the layer on top of it where you can navigate through comments, etc.

  • Convert PDF files to HTML and work from there. The problem here was that they would either require the right PDF files (for example, not scanned), or really good OCRs that seem a little tedious.

  • Convert PDF files to images and work from there. I am afraid that this will create massive images. We are talking about PDF files, which can be hundreds of pages. Of course, one option would be to simply display one PDF page (image) at a time.

And the last - should I take a look at Silverlight for this or go with ASP.NET?

Ideas and materials regarding this project are greatly appreciated.

+4
source share
2 answers

You can watch PDFWebViewer.NET from TallComponents. This is an ASP.NET Ajax viewer that uses the PDF-to-image approach. The website has a demo version and a free downloadable trial version.

For comments, you can add some code to handle comments. TallComponents also has other components that allow you to manipulate PDF documents to add PDF comments (Acrobat compatible).

Regarding your question about Silverlight and ASP.NET, I think this is a choice that you should make based on your target audience. If you expect a large number of Windows users, Silverlight will be fine. If you need to support non-Windows users and mobile devices, you will probably be better off with html and a script (next year or so anyway).

As for your concerns about massive images for the PDF-to-image approach; that it all depends. A page image with a screen resolution will compress very well for most documents, and good PDF rendering will be optimized for the required zoom ratio. In addition, the PDF format allows you to quickly get random access, so that the rendering pages selectively look normal. PDFWebViewer.NET is fast enough to display most documents per page on demand when viewing a document.

Full disclosure: I work for TallComponents on PDFWebViewer.NET.

+1
source

I myself am a Silverlight developer, so my answer will be somewhat biased. But if I were you, I would consider this component:
http://www.pdftron.com/silverdox/index.html

If this component does an excellent job with your .pdf files, the commenting function itself should not be too complicated to implement in Silverlight. Of course, this depends on your exact requirements, as well as how much experience you have with technology.

In any case, this will be my starting point.

+2
source

Source: https://habr.com/ru/post/1335253/


All Articles