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
FacebookFacebook 

Render Page as PDF

Hi,

 

     I am trying to render a visual force page as PDF that displays Photos related to certain product.When the photos are being displayed in the PDFif there are more than 12 photos the page breaks and some space is appearing and the remaining photos are displayed in the next page.What i need now is to display Header and footer for the second page and then display the remaining photos..I am using a repeater in my page in order to display the photos.

 

Any suggestions are higly appreciated.

 

 

Regards,

Abhi

Pradeep_NavatarPradeep_Navatar

You can do this through css style declared in the visual force page:

 

                                                <style>
  @page :first
  {
                size:landscape;
                margin-top:0%;
                @top-center
                {
                 content: element(header2);
                }
  }
  @page
  {
                size:landscape;
                margin-top:18%;
                @top-center
                {
                                content: element(header1);
                }
                @bottom-right
                {
                                content: "Page: " counter(page) " / " counter(pages);font-size: 80%;
                }
  }
    div.header1
                 {
                   position: running(header1);
                   width:703px;
                   height:30px;
                   padding-bottom:120px;
                   padding-left:9px;
                 }
                 div.header2
                 {
                   width:703px;
                   height:30px;
                   padding-bottom:120px;   
                 }
</style>

Arfa Rfa3Arfa Rfa3
Transform Your Body and Mind at Brad Gym: Unleash Your Inner StrengthIntroduction: Are you tired of your monotonous workout routine? Do you feel like you're not reaching your fitness goals despite putting in the effort? If so, it's time to discover the power of Brad Gym. In this article, we'll explore what makes Brad Gym unique and how it can help you transform your body and mind. you can check here (https://bradgym.com/best-leg-extension-machine/)