+ Start a Discussion
Uditi_VermaUditi_Verma 

Record detail page redirection upon PDF generate button.

Hi,

I have created a VF page and its controller extension to generate and save a PDF report in related Files on a button click. Now on button click, I just want a PDF should get saved in related Files to the record and the page should get redirected to its record detail page without displaying the PDF. This is to be done in Lightning and not Classic. So, I can't even pass record link and a record ID anywhere.

Please do suggest ways to do this. Any help would be highly appreciated.

Best Answer chosen by Uditi_Verma
bhanu_prakashbhanu_prakash
Hi Uditi,
Mark as best answer, If it resloves !!

Check these link : https://blog.jeffdouglas.com/2010/07/14/attach-a-pdf-to-a-record-in-salesforce/

Mark as resloved if it helps :) :)
Thanks, 
Bhanu Prakash
visit ForceLearn.com​​ 

All Answers

bhanu_prakashbhanu_prakash
Hi Uditi,
Mark as best answer, If it resloves !!

Check these link : https://blog.jeffdouglas.com/2010/07/14/attach-a-pdf-to-a-record-in-salesforce/

Mark as resloved if it helps :) :)
Thanks, 
Bhanu Prakash
visit ForceLearn.com​​ 
This was selected as the best answer
bhanu_prakashbhanu_prakash
Thanks Uditi, Marking as Best Answer.

Thanks, 
Bhanu Prakash
visit ForceLearn.com​​