We have scenario where visualforce pages need to display pdfs in ipad browsers. We were able to display attachments but not files.

Is there a way/solution to display pdfs in ipads that works with attachment/files lightning/classic and in any device ?

  • 1) Is this using the Salesforce app, or using Salesforce in a browser? 2) Are these PDFs generated on-the-fly in Visualforce or saved as Salesforce Files? 3) Can you show us the code you've tried using so far?
    – Charles T
    Jun 28, 2018 at 23:16
  • 1) Salesforce in browser 2) Saved Files and attachments. 3) I tried below code in visualforce, $('.pdfViewer').attr('src',/sfc/servlet.shepherd/document/download/'+fileid) <iframe class="pdfViewer" src=""></iframe> Jun 29, 2018 at 0:50
  • Is there a reason you don't want to just pop the PDF directly up so the OS will open it? It's really the best PDF-reading experience you can get on an iPad.
    – Charles T
    Jun 29, 2018 at 12:00


You must log in to answer this question.

Browse other questions tagged .