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
Jonathan Wolff 7Jonathan Wolff 7 

List Button to print pdf

Hello, I made a Visualforce page to show fields from accounts. I want to make a List Button to print the PDF for every account I chose. 
Can you give me a guide how to do it?

My VF:

<apex:page standardController="Account" renderAs="pdf" > <h1>Welcome to Universal Samples!</h1> <p>Thank you, <b><apex:outputText value=" {!Account.Name}"/></b>, for becoming a new account with Universal Samples.</p> <p>Your account details are:</p> <table> <tr><th>Account Name</th> <td><apex:outputText value="{!Account.Name}"/></td> </tr> <tr><th>Account Rep</th> <td><apex:outputText value="{!Account.Owner.Name}"/></td> </tr> <tr><th>Customer Since</th> <td><apex:outputText value="{0,date,long}"> <apex:param value="{!Account.CreatedDate}"/> </apex:outputText></td> </tr> </table> </apex:page>
PriyaPriya (Salesforce Developers) 

Hi Jonathan,

Please try to implement the similar logic used in the below link :- 

https://developer.salesforce.com/forums/?id=906F0000000Ai0XIAS

 

Regards,

Priya Ranjan