KoolReport's Forum

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

Export to PDF from report view #1840

Open Ron opened this topic on on Jan 11 - 1 comments

Ron commented on Jan 11

Hi,

I am trying to understand how can I export my current report view which is open in the browser to PDF. in your example in the documentation it is exporting to a predefined .view.pdf file. I am trying to print the current view because sometimes I am moving with the columns or searching for a specific row in the search box. I am using the DataGrid widget

Sebastian Morales commented on Jan 12

Oh, just use your web view as the pdf view in your export command:

    $report->run()->export("MyReport")->toBrowser("Myreport.pdf"); //this uses MyReport.view.php to render pdf instead of MyReportPDF.view.php

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