Is there any way to open pdf from a location to a page?

Is there any way to open pdf from a location to a page?

  

The file path is stored in my database and the file is in a server location. I want to show the pdf file (Inside a container) when clicking on the file name. Is there any way to do that?



Hi Anjitha,

Try this component https://www.outsystems.com/forge/component/2661/pdfjs-viewer/

It has a embedeed viewer to open pdf files in your browser.


Best regards

Fabio Fantato


Fábio Fantato wrote:

Hi Anjitha,

Try this component https://www.outsystems.com/forge/component/2661/pdfjs-viewer/

It has a embedeed viewer to open pdf files in your browser.


Best regards

Fabio Fantato


Thanks Fábio Fantato. I think this one shows the pdf in a different page. I need to show it in a page which contains a tree structure on left side and when I click on the leaf node containing the pdf file name, the pdf file should be previewed on the right side (inside a container widget). Is it possible using pdfjs-viewer?


You can use the object HTML tag to show a PDF in your page:

<object data="your_url_to_pdf" type="application/pdf">
  <embed src="your_url_to_pdf" type="application/pdf" />
</object>