You need to sign in to do that
Don't have an account?
Kavya M 43
Hellooooooooo
I want to develop a button in my page. Let's say that button name is "Print". When you click on that "Print" button it should print the page in a PPT / PDF format.
I want your inputs to get an idea about this. I really don't know where to start and how to start. Can you guys help me?
I want your inputs to get an idea about this. I really don't know where to start and how to start. Can you guys help me?
Greetings to you!
Below is the sample code which I have tested in my org and it is working fine. Kindly modify the code as per your requirement.
Visualforce:
Controller:
If you want to render the page in PDF from different visualforce page button, you can use the below code.
Visualforce 1:
Visualforce 2:
If you want to format a visualforce page rendered as PDF, you can refer to below knowledge article.
https://help.salesforce.com/articleView?id=000004706&language=en_US&type=1
I hope it helps you.
Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.
Thanks and Regards,
Khan Anas