KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

A1 and A2 size generate PDF #3317

Open Giri Rajan opened this topic on on Jul 12 - 7 comments

Giri Rajan commented on Jul 12

Hi Team,

Is there any possible to generate Pdf with A1 and A2 paper size because my report is much bigger then A3 paper size.

Sebastian Morales commented on Jul 17

May I know whether you use Export or CloudExport package?

Giri Rajan commented on Jul 17

I am using Export package

Sebastian Morales commented on Jul 18

It looks like the "format" property of Export only accepts from 'A3', 'A4' onward. For printing in A1 or A2 size you would have to to set your PDF view page size via CSS like this:

.page {
    position:relative;
    border: ...;
    width:calc(210mm * 1.25); /* replace A4 width size here with A1 or A2 width size */
    height:calc(297mm * 1.25); /* replace A4 height size here with A1 or A2 height size */
    padding:...
}
<div class="page">
    ...
</div>
Giri Rajan commented on Aug 2

I have implemented a page width setting, but it currently generates only A3 size PDFs. To generate PDFs in A1 and A2 sizes, can you give sample code

Giri Rajan commented on Aug 8

Hi team, I added below code for setting page size but its look like same A4 size while generate PDF

.page {

    position:relative;
    width:calc(594mm * 1.25); /* replace A4 width size here with A1 or A2 width size */
    height:calc(841mm * 1.25); /* replace A4 height size here with A1 or A2 height size */
}
Sebastian Morales commented on Aug 13

We will investigate this issue and let you know of a solution. Tks,

Sebastian Morales commented on Aug 14

Pls try to set pdf width and height directly like this and let us know the result:

    $report->export("MyReportPDF")
        ->settings([
            ...
        ->pdf(array(
            "width"=>"16.5in", //A2 size
            "height"=>"23.4in", //A2 size

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
None yet

None