@@ -34,6 +34,7 @@ You can configure the following parameters of the viewer:
3434* Height : sets the height of the iframe
3535* FilePath : path to the file to be render on the HTML page
3636* TempDirectoryPath : path for the temporary converted to PDF files (see Word , PowerPoint and Excel sections below ).
37+ * PdfRenderer : is used by documents converted to PDFs (see below ) and you can choose between [PDF .js ](https :// mozilla.github.io/pdf.js/) and [Adobe Reader](https://acrobat.adobe.com/uk/en/). Adobe Reader is used by default now, but this requires Adobe to be installed client-side. PDF.js is relying only on JavaScript, but the library is still developing. For further information check their websites.
3738
3839### How to embed PDF documents?
3940For PDF documents , a simple iframe is generated , so the following line is enough to embed a document :
@@ -42,15 +43,18 @@ For PDF documents, a simple iframe is generated, so the following line is enough
4243< cc :DocumentViewer runat = " server" Width = " 500" Height = " 500" FilePath = " ~/sample.pdf" / >
4344```
4445
46+ You can additionally set the PdfRenderer parameter if you want to use PDF .js .
47+
4548### How to embed Word documents?
4649Word documents are converted to PDF documents , then rendered in iframe . You should have Microsoft Office installed on the server for this to work .
4750You can embed a Word document as shown below :
4851
4952```html
50- < cc :DocumentViewer runat = " server" Width = " 500" Height = " 500" FilePath = " sample.docx" TempDirectoryPath = " ~/TempFiles" / >
53+ < cc :DocumentViewer runat = " server" Width = " 500" Height = " 500" FilePath = " sample.docx" TempDirectoryPath = " ~/TempFiles" PdfRenderer = " PdfJs " / >
5154```
5255
5356If TempDirectoryPath is not supplied , the converted documents can be found in the Temp directory of the project root .
57+ If PdfRenderer is not supplied , Adobe Reader is used by default .
5458
5559
5660### How to embed PowerPoint documents?
@@ -62,6 +66,7 @@ You can embed a PowerPoint document as shown below:
6266```
6367
6468If TempDirectoryPath is not supplied , the converted documents can be found in the Temp directory of the project root .
69+ You can additionally set the PdfRenderer parameter if you want to use PDF .js .
6570
6671### How to embed Excel documents?
6772Excel documents are converted to HTML files , then rendered in iframe . You should have Microsoft Office installed on the server for this to work .
@@ -72,6 +77,7 @@ You can embed an Excel document as shown below:
7277```
7378
7479If TempDirectoryPath is not supplied , the converted documents can be found in the Temp directory of the project root .
80+ You can additionally set the PdfRenderer parameter if you want to use PDF .js .
7581
7682### Do you have an issue?
7783Have a bug or a feature request ? Please search for existing and closed issues before submitting a new one . If your problem or idea is not addressed yet , please open a new issue .
0 commit comments