New answers tagged


Check the page's API version. In my case, the apex code took about 1 sec of CPU time, and the generating of the PDF itself took almost 18 seconds. I found out that it uses an old api version (27). i updated it to 48 and it soved the problem.


Oh dear, there is no issue in creating the respective PDFs. With document preview, a PDF file is generated and then left to the browser to render it. If you click on a saved PDF, Salesforce renders a preview image. This preview image is not rendered correctly, looking like boldness looks the same.


I made a "Content Document" so I could then create a public link and use it in the front: public class PX_IRN_PDF_CTR { @AuraEnabled public static String generaPDF( Id accId1){ String url = '/apex/PX_IRN_PAGE?id=' + accId1; PageReference pageRef = new PageReference(url); Blob ret = pageRef.getContentAsPDF(); String ...


Ensuring the footer doesn't appear on the last page should be possible with @page and Named Pages in your CSS. Unfortunately there's no :last psuedo-selector for @page, otherwise that would get the job done. First, add some CSS for your last page: div.lastPage { page: lastPage; /* This assigns the name, basically, if this class appears, then this ...


Check critical updates for 'Lightning Experience Honors Target Values for Hyperlinks in Formula Fields' Also you should use <apex:page renderAs="pdf"> instead of your JS approach.


From Setup, enter Visualforce Pages in the Quick Find box, then select Visualforce Pages. Click Edit for the page you want to make available for your community. Select Available for Salesforce mobile apps and Lightning Pages and click Save.

Top 50 recent answers are included