function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Phuc 2Phuc 2 

Open Pdf in Aura Component

Hello All,
I have an aura component and I want to allow a user to click on a link to open a pdf.  I have the pdg, how can I add the pdf and make it accessible?
Thanks,
Michael
VinayVinay (Salesforce Developers) 
Hi Michael,

Check below example reference to generate/view PDF using Lightning Components

https://www.vermanshul.com/2017/07/lightning-generate-pdf-from-lightning.html
https://gist.github.com/toanshulverma/16244d19ac68364cb75443695d81403b

Similar example below.
https://salesforce.stackexchange.com/questions/205065/how-to-generate-view-pdf-using-lightning-components

Please mark as Best Answer if above information was helpful.

Thanks,
Phuc 2Phuc 2
Thanks for teh reply.  I have the pdf file.  I need to have it open when the user selects the file and it needs to be editable.  Right now they would have to dowload the file and reopen for them to be able to edit it.