PDF Previewing and viewing

烂漫一生 提交于 2019-11-30 21:29:52
Renaud Bompuis

For creating the PDF preview, first have a look at some other discussions on the subject on StackOverflow:

If these don't answer your question, you can try a couple more things:

  • You can get a commercial renderer (PDFViewForNet, PDFRasterizer.NET, ABCPDF, ActivePDF, ...).
    Most are fairly expensive though, especially if all you care about is making thumbnails.
  • There is a CodeProject article that shows how to use the Adobe ActiveX, but it may be out of date, easily broken by new releases and its legality is murky.
  • Install GhostScript on the server and request rendered thumbnails of any page from it.
    I did a small project that you will find on the Developer Express forums as an attachment.
    Be careful of the license requirements for GhostScript through.
    I use it for an internal software and it's working pretty well.

Hope this helps.

Here I render the jpeg thumbnails of the first page of the pdf document when a file is uploaded. When the user clicks he can download the document (or open them direcly in the browser) to read and print them.

Update: to create the thumbnails I used a .net component called PDFView4NET from O2Solutions

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!